In my setup the direct use of $_SESSION['wsDomain'] at line 1237 of LdapAuthentication.php causes problems: Im my case there sometimes is a token but the wsDomain-member of the $_SESSION array is not (yet) set.
Looking through the code I came up with this solution:
diff --git a/LdapAuthentication.php b/LdapAuthentication.php index 44e47d4..462f9c9 100644 --- a/LdapAuthentication.php +++ b/LdapAuthentication.php @@ -1234,7 +1234,7 @@ class LdapAuthenticationPlugin extends AuthPlugin { # We must set a user option if we want token based logins to work if ( $user->getToken( false ) ) { $this->printDebug( "User has a token, setting domain in user options.", NONSENSITIVE ); - self::saveDomain( $user, $_SESSION['wsDomain'] ); + self::saveDomain( $user, $this->getDomain() ); } # Let other extensions update the user
I think this is the correct way of doing it especially after reading the comments in getDomain(). :-)
What do you think?