saml_sp.api.inc in SAML Service Provider 8.3
Same filename and directory in other branches
API hooks for SAML Service Provider module.
File
saml_sp.api.incView source
<?php
/**
* @file
* API hooks for SAML Service Provider module.
*/
use OneLogin\Saml2\Settings;
/**
* Alter the settings used when generating SAML requests.
*
* @param \OneLogin\Saml2\Settings $settings
* The Settings object.
*/
function hook_saml_sp_settings_alter(Settings &$settings) {
// Change the consuming URL to a custom endpoint.
if ($settings->login_url == 'http://example.com/saml/foo') {
$settings->spReturnUrl = url('saml/custom_action', [
'absolute' => TRUE,
]);
}
}
Functions
Name | Description |
---|---|
hook_saml_sp_settings_alter | Alter the settings used when generating SAML requests. |