Created
May 10, 2020 22:19
-
-
Save dorian-e3/8464486152192969b3a95660f2539350 to your computer and use it in GitHub Desktop.
Saml Authsources Config Sample
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Enviornment specific changes made at bottom of file | |
*/ | |
$config = [ | |
// For logging into saml admin pages | |
'admin' => [ | |
'core:AdminPassword', | |
], | |
// SAML 2.0 Authentication Configuration | |
'default-sp' => [ | |
'saml:SP', | |
// Don't send NameIDPolicy per request of IDP | |
'NameIDPolicy' => FALSE, | |
// The entity ID of this SP. | |
'entityID' => 'https://www.enviornment-specific-drupal-domain.com', | |
// The entity ID of the IdP this SP should contact. | |
// Normally an address | |
'idp' => "https://sts.windows.net/sample/", | |
// Private key you generate yourself in cert directory | |
// openssl req -newkey rsa:3072 -new -x509 -days 3652 -nodes -out saml.crt -keyout saml.pem | |
'privatekey' => 'sample.pem', | |
], | |
]; | |
/* | |
* Enviornment specific switching if SSO is enabled on multiple enviornments | |
*/ | |
if(isset($_ENV['AH_SITE_ENVIRONMENT']) && $_ENV['AH_SITE_ENVIRONMENT'] == 'prod') { | |
$config['default-sp']['entityID'] = 'https://www.sample.com'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment