Note. This use case is a variant when it comes to structure in the config.json file only. The use case will work but it is explained more in detail of its purpose in "Multiple SAML IdP's configured"
If you have a large config.json file when, for example, multiple IdPs then it could be more convinent to split the JSON file in several files where one file is IdP1 and another IdP2 and the config.json file is the main file.
config.json support something called includes where you can include JSON content from a separate file. You can either point out one file to include or a folder with several JSON files.
There are some use case where we use this technic. See "Portal" use case or "Globals and Includes" use case.
In this scenario we have two IdPs. Each IdP has one authenticator part and one pipes part. So total we have 6 use case files for this use case.
Complete config.json file
Copy {
"globals" : "@include:globals.json" ,
"modules" : [
{
"name" : "CefEventModule" ,
"config" : {}
} ,
{
"name" : "HttpClient" ,
"config" : {
"name" : "default" ,
"idle_timeout_ms" : 5000 ,
"connect_timeout_ms" : 5000
}
} ,
{
"name" : "LdapClient" ,
"enabled" : true ,
"instances" : 1 ,
"config" : {
"name" : "${globals.ldap.ldap1.name}" ,
"connection" : {
"host" : "${globals.ldap.ldap1.connection.host}" ,
"port" : "${globals.ldap.ldap1.connection.port}" ,
"bind_dn" : "${globals.ldap.ldap1.connection.bind_dn}" ,
"bind_password" : "${globals.ldap.ldap1.connection.bind_password}" ,
"use_ssl" : "${globals.ldap.ldap1.connection.use_ssl}" ,
"ssl_trust_all" : "${globals.ldap.ldap1.connection.ssl_trust_all}"
}
}
} ,
{
"name" : "SmtpClient" ,
"enabled" : true ,
"config" : {
"name" : "${globals.smtp.smtp1.name}" ,
"host" : "${globals.smtp.smtp1.host}" ,
"port" : "${globals.smtp.smtp1.port}" ,
"user_name" : "${globals.smtp.smtp1.user_name}" ,
"password" : "${globals.smtp.smtp1.password}" ,
"auth_methods" : "DIGEST-MD5, CRAM-SHA256, LOGIN"
}
} ,
{
"name" : "SAML" ,
"config" : {
"metadata_cache" : "${globals.saml.generic.metadata_cache}" ,
"http_port" : "${globals.http.port}" ,
"http_use_ssl" : true ,
"http_keystore_ref" : {
"type" : "${globals.keystore.https.ref.type}" ,
"path" : "${globals.keystore.https.ref.path}" ,
"password" : "${globals.keystore.https.ref.password}"
} ,
"http_keystore_type" : "${globals.keystore.https.type}" ,
"http_key_alias" : "${globals.keystore.https.http_key_alias}" ,
"http_key_password" : "${globals.keystore.https.http_key_password}" ,
"enable_http" : true ,
"metadata_template" : [
{
"id" : "${globals.saml.idp1.metadata_id}" ,
"metadata_file_path" : "${globals.saml.idp1.metadata_file_path}" ,
"sign_ref" : [
{
"keystore" : {
"alias" : "${globals.keystore.saml.sign_ref_keystore_alias}" ,
"key_password" : "${globals.keystore.saml.sign_ref_keystore_key_password}" ,
"password" : "${globals.keystore.saml.sign_ref_keystore_password}" ,
"path" : "${globals.keystore.saml.sign_ref_keystore_path}"
}
}
]
} ,
{
"id" : "${globals.saml.idp2.metadata_id}" ,
"metadata_file_path" : "${globals.saml.idp2.metadata_file_path}" ,
"sign_ref" : [
{
"keystore" : {
"alias" : "${globals.keystore.saml.sign_ref_keystore_alias}" ,
"key_password" : "${globals.keystore.saml.sign_ref_keystore_key_password}" ,
"password" : "${globals.keystore.saml.sign_ref_keystore_password}" ,
"path" : "${globals.keystore.saml.sign_ref_keystore_path}"
}
}
]
}
] ,
"metadata" : [
{
"path": "${globals.file_paths.base_dir}/config/resources_internal/saml/sp_metadata_files/sp_portal.xml"
} ,
{
"path": "${globals.file_paths.base_dir}/config/resources_internal/saml/sp_metadata_files/sp_pwdreset.xml"
}
]
}
} ,
{
"name" : "AuthN" ,
"_info" : "*** This is AuthN for IdP 1 ***" ,
"enabled" : true ,
"config" : "@include:IdP_1_AuthN.json"
} ,
{
"name" : "Pipes" ,
"_info" : "*** This is Pipes for IdP 1 ***" ,
"config" : "@include:IdP_1_Pipes.json"
} ,
{
"name" : "AuthN" ,
"_info" : "*** This is AuthN for IdP 2 ***" ,
"enabled" : true ,
"config" : "@include:IdP_2_AuthN.json"
} ,
{
"name" : "Pipes" ,
"_info" : "*** This is Pipes for IdP 2 ***" ,
"config" : "@include:IdP_2_Pipes.json"
}
]
}