diff options
author | Jaime Perez Crespo <jaime.perez@uninett.no> | 2015-08-30 21:49:31 +0200 |
---|---|---|
committer | Jaime Perez Crespo <jaime.perez@uninett.no> | 2015-08-30 21:49:31 +0200 |
commit | d501d6b582933cc4549bf0dadc97e11ee5b13b8c (patch) | |
tree | d6c0fefe49017cfac16a3b3c2f1a4d982fc0798b /lib/SimpleSAML/Auth/Source.php | |
parent | 634648072090faae743d1fe3cbf01a8d0b9f2775 (diff) | |
download | simplesamlphp-d501d6b582933cc4549bf0dadc97e11ee5b13b8c.zip simplesamlphp-d501d6b582933cc4549bf0dadc97e11ee5b13b8c.tar.gz simplesamlphp-d501d6b582933cc4549bf0dadc97e11ee5b13b8c.tar.bz2 |
Move SimpleSAML_Auth_Default::initLogout() to SimpleSAML_Auth_Source and deprecate the former.
Diffstat (limited to 'lib/SimpleSAML/Auth/Source.php')
-rw-r--r-- | lib/SimpleSAML/Auth/Source.php | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/lib/SimpleSAML/Auth/Source.php b/lib/SimpleSAML/Auth/Source.php index fc3b9e8..891ac6b 100644 --- a/lib/SimpleSAML/Auth/Source.php +++ b/lib/SimpleSAML/Auth/Source.php @@ -277,6 +277,26 @@ abstract class SimpleSAML_Auth_Source /** + * Start logout. This method starts a logout operation from the current authentication source. + * + * This method never returns. + * + * @param string $returnURL The URL we should redirect the user to after logging out. No checking is performed on + * the URL, so make sure to verify it on beforehand if the URL is obtained from user input. Refer to + * \SimpleSAML\Utils\HTTP::checkURLAllowed() for more information. + */ + public function initLogout($returnURL) + { + assert('is_string($returnURL)'); + assert('is_string($authority)'); + + self::initLogoutReturn($returnURL); + + \SimpleSAML\Utils\HTTP::redirectTrustedURL($returnURL); + } + + + /** * Called when logout operation completes. * * This function never returns. |