Skip to content
Snippets Groups Projects

Fix bug with non-HTTP Shib sessions being valid for HTTP sessions

Merged Andy Summers requested to merge andrew-summers/uw-php-security:test-fix into master
6 files
+ 100
6
Compare changes
  • Side-by-side
  • Inline
Files
6
@@ -28,8 +28,8 @@ class FederatedPreauthUserDetailsProvider implements UserDetailsProvider
public function loadUser()
{
// Return null if no Shib session is found
if (empty(getenv(FederatedPreauthUserDetailsProvider::SHIB_SESSION_ID)) &&
empty(getenv(FederatedPreauthUserDetailsProvider::SHIB_SESSION_ID_HTTP))) {
if ($this->httpHeaders && !getenv(FederatedPreauthUserDetailsProvider::SHIB_SESSION_ID_HTTP) ||
!$this->httpHeaders && !getenv(FederatedPreauthUserDetailsProvider::SHIB_SESSION_ID)) {
return null;
}
Loading