mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
py3: custodia: basedn must be unicode
basedn in custodia related modules has type bytes, that causes issues in Py3 when strings were concatenated with bytes ``` malformed RDN string = "cn=custodia,cn=ipa,cn=etc,b'dc=example,dc=com'" ``` https://fedorahosted.org/freeipa/ticket/4985 Reviewed-By: Jan Cholasta <jcholast@redhat.com>
This commit is contained in:
committed by
Jan Cholasta
parent
2674a217ac
commit
c27a46177c
@@ -23,7 +23,7 @@ class iSecLdap(object):
|
||||
if self._basedn is None:
|
||||
conn = self.connect()
|
||||
r = conn.search_s('', ldap.SCOPE_BASE)
|
||||
self._basedn = r[0][1]['defaultnamingcontext'][0]
|
||||
self._basedn = r[0][1]['defaultnamingcontext'][0].decode('utf-8')
|
||||
return self._basedn
|
||||
|
||||
def connect(self):
|
||||
|
||||
Reference in New Issue
Block a user