Fixed altClass group retrieval for regexldap

This commit is contained in:
Adolfo Gómez García 2020-09-08 12:21:18 +02:00
parent d46c806ae3
commit 2c27061534
2 changed files with 5 additions and 4 deletions

View File

@ -276,9 +276,11 @@ class RegexLdap(auths.Authenticator):
attrList=attributes,
sizeLimit=LDAP_RESULT_LIMIT
):
for k, v in usr.items():
kl = k.lower()
for attr in self.__getAttrsFromField(self._groupNameAttr):
v = usr.get(attr)
if not v:
continue
kl = attr.lower()
# If already exists the field, check if it is a list to add new elements...
if kl in usr:
# Convert existing to list, so we can add a new value

View File

@ -152,7 +152,6 @@ def getAsDict(
yield dct
def getFirst(
con: typing.Any,
base: str,