lemur/lemur/auth
Frederic Brin 57208fe198 Fix group lookup when AD DNS Referal is in lookup path
Fix an issue when the DNS AD referal is in the path.
An Exception is raised, with the following stacktrace::

  Traceback (most recent call last):
    File "/www/lemur/lemur/auth/views.py", line 317, in post
      user = ldap_principal.authenticate()
    File "/www/lemur/lemur/auth/ldap.py", line 147, in authenticate
      self._bind()
    File "/www/lemur/lemur/auth/ldap.py", line 216, in _bind
      self.ldap_groups.append(values["cn"][0].decode("ascii"))
  TypeError: list indices must be integers or slices, not str

This is issue is trigerred by some extra rows that referrences
the DNS subtree::

   ['ldaps://DomainDnsZones.xxxx']

Limiting the extraction to the expected dicts fix this issue.
2020-11-09 09:40:28 +01:00
..
__init__.py initial commit 2015-06-22 13:47:27 -07:00
ldap.py Fix group lookup when AD DNS Referal is in lookup path 2020-11-09 09:40:28 +01:00
permissions.py Enhance domains query and sensitive domain checking code; Allow creation of opt-out roles via config 2019-05-30 10:21:44 -07:00
service.py pass algorithm to jwt.decode() during login 2020-11-02 17:37:04 -08:00
views.py OAUTH2 fixes 2020-04-04 11:32:23 -04:00