diff --git a/lib/authentication/authenticationutil.inc.php b/lib/authentication/authenticationutil.inc.php index 3fc770c..18f2ab1 100644 --- a/lib/authentication/authenticationutil.inc.php +++ b/lib/authentication/authenticationutil.inc.php @@ -76,14 +76,6 @@ class KTAuthenticationUtil { $oProvider = KTAuthenticationUtil::getAuthenticationProviderForSource($oSource); $res = $oProvider->autoSignup($sUsername, $sPassword, $aExtra, $oSource); if ($res) { - $oUser = User::getByUsername($sUsername); - // TODO: The check for this lower down....checkPassword - if(empty($sPassword) || is_null($oUser) || PEAR::isError($oUser)){ - return false; - } - if(!KTAuthenticationUtil::checkPassword($oUser, $sPassword)){ - return false; - } return $res; } } diff --git a/plugins/ktstandard/ldap/ldapbaseauthenticationprovider.inc.php b/plugins/ktstandard/ldap/ldapbaseauthenticationprovider.inc.php index 1772bcb..e67a53b 100644 --- a/plugins/ktstandard/ldap/ldapbaseauthenticationprovider.inc.php +++ b/plugins/ktstandard/ldap/ldapbaseauthenticationprovider.inc.php @@ -639,6 +639,11 @@ class KTLDAPBaseAuthenticator extends Authenticator { } function checkSignupPassword($sUsername, $sPassword) { + + if(empty($sPassword) || empty($sUsername)) { + return false; + } + $aUsers = $this->findUser($sUsername); if (empty($aUsers)) { return false;