Change LDAP errors into debug statements to reduce log clutter
Fixes #2083
This commit is contained in:
parent
a4fce1b102
commit
536809a992
1 changed files with 4 additions and 4 deletions
|
@ -107,11 +107,11 @@ class LDAPUsers(FederatedUsers):
|
|||
subquery = u'(%s=%s)' % (self._uid_attr, username_or_email)
|
||||
return (conn.search_s(referral_dn, ldap.SCOPE_BASE, subquery), None)
|
||||
except ldap.LDAPError:
|
||||
logger.exception('LDAP referral search exception')
|
||||
logger.debug('LDAP referral search exception')
|
||||
return (None, 'Username not found')
|
||||
|
||||
except ldap.LDAPError:
|
||||
logger.exception('LDAP search exception')
|
||||
logger.debug('LDAP search exception')
|
||||
return (None, 'Username not found')
|
||||
|
||||
def _ldap_user_search(self, username_or_email, limit=20):
|
||||
|
@ -234,11 +234,11 @@ class LDAPUsers(FederatedUsers):
|
|||
self._allow_tls_fallback):
|
||||
pass
|
||||
except ldap.INVALID_CREDENTIALS:
|
||||
logger.exception('Invalid LDAP credentials')
|
||||
logger.debug('Invalid LDAP credentials')
|
||||
return (None, 'Invalid password')
|
||||
|
||||
except ldap.INVALID_CREDENTIALS:
|
||||
logger.exception('Invalid LDAP credentials')
|
||||
logger.debug('Invalid LDAP credentials')
|
||||
return (None, 'Invalid password')
|
||||
|
||||
return self._credential_for_user(found_response)
|
||||
|
|
Reference in a new issue