diff --git a/phpgwapi/inc/class.auth.inc.php b/phpgwapi/inc/class.auth.inc.php index 9ccffe3369..696987845a 100644 --- a/phpgwapi/inc/class.auth.inc.php +++ b/phpgwapi/inc/class.auth.inc.php @@ -76,11 +76,11 @@ class auth // retrieve the timestamp regarding the last change of the password from auth system and store it with the session static $alpwchange_val; static $pwdTsChecked; - if (is_null($pwdTsChecked) && is_null($alpwchange_val)) + if (is_null($pwdTsChecked) && is_null($alpwchange_val) || (string)$alpwchange_val === '0') { $alpwchange_val =& egw_cache::getSession('phpgwapi','auth_alpwchange_val'); // set that one with the session stored value // initalize statics - better readability of conditions - if (is_null($alpwchange_val)) + if (is_null($alpwchange_val) || (string)$alpwchange_val === '0') { $backend_class = 'auth_'.$GLOBALS['egw_info']['server']['auth_type']; $backend = new $backend_class; diff --git a/phpgwapi/inc/class.auth_ads.inc.php b/phpgwapi/inc/class.auth_ads.inc.php index 0fda5f835a..41942dfda8 100644 --- a/phpgwapi/inc/class.auth_ads.inc.php +++ b/phpgwapi/inc/class.auth_ads.inc.php @@ -207,7 +207,7 @@ class auth_ads implements auth_backend $username = $GLOBALS['egw']->accounts->id2name($account_id); } // Check the old_passwd to make sure this is legal - if(!$admin && !$adldap->authenticate($username, $old_passwd)) + if(!$admin && !$this->authenticate($username, $old_passwd)) { //error_log(__METHOD__."() old password '$old_passwd' for '$username' is wrong!"); return false;