diff --git a/shibboleth.php b/shibboleth.php index c41e553..148a67f 100644 --- a/shibboleth.php +++ b/shibboleth.php @@ -376,7 +376,8 @@ function shibboleth_admin_hooks() { function shibboleth_session_active( $auto_login = false ) { $active = false; $method = shibboleth_getoption( 'shibboleth_attribute_access_method' ); - $session = shibboleth_getenv( 'Shib-Session-ID' ); + $shib_headers = shibboleth_getoption( 'shibboleth_headers', array(), true ); + $session = shibboleth_getenv( $shib_headers['username']['name'] ); if ( $session && 'http' !== $method ) { $active = true;