Merge pull request #17595 from nextcloud/fix/noid/wrong-pwd-apple-open-dir

treat LDAP error 50 as auth issue, prevents lost server connection errors
This commit is contained in:
blizzz 2019-10-21 11:55:51 +02:00 committed by GitHub
commit a7193ce781
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -675,7 +675,8 @@ class Connection extends LDAPUtility {
ILogger::WARN); ILogger::WARN);
// Set to failure mode, if LDAP error code is not LDAP_SUCCESS or LDAP_INVALID_CREDENTIALS // Set to failure mode, if LDAP error code is not LDAP_SUCCESS or LDAP_INVALID_CREDENTIALS
if($errno !== 0x00 && $errno !== 0x31) { // or (needed for Apple Open Directory:) LDAP_INSUFFICIENT_ACCESS
if($errno !== 0 && $errno !== 49 && $errno !== 50) {
$this->ldapConnectionRes = null; $this->ldapConnectionRes = null;
} }