From: Michael Tremer Date: Wed, 5 Oct 2022 10:25:19 +0000 (+0000) Subject: ldap: Search for all persons in the database X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4ea3fb3e2da5ba6376861effa4e64b7456eb7a61;p=pbs.git ldap: Search for all persons in the database Not only those who have a POSIX account. Signed-off-by: Michael Tremer --- diff --git a/src/buildservice/ldap.py b/src/buildservice/ldap.py index 679ebd5e..0ca73ce0 100644 --- a/src/buildservice/ldap.py +++ b/src/buildservice/ldap.py @@ -68,7 +68,7 @@ class LDAP(base.Object): if not uid: return None, None - result = self.search("(&(objectClass=posixAccount)(uid=%s))" % uid, limit=1, **kwargs) + result = self.search("(&(objectClass=person)(uid=%s))" % uid, limit=1, **kwargs) for dn, attrs in result: return dn, attrs @@ -79,7 +79,7 @@ class LDAP(base.Object): if not mail: return None, None - result = self.search("(&(objectClass=posixAccount)(mail=%s))" % mail, limit=1, **kwargs) + result = self.search("(&(objectClass=person)(mail=%s))" % mail, limit=1, **kwargs) for dn, attrs in result: return dn, attrs