From 0a1d7f2e01819ad6e4a19d0416b3a01883dea7d0 Mon Sep 17 00:00:00 2001 From: Martin Basti Date: Jan 24 2017 12:25:47 +0000 Subject: py3: add_entry_to_group: attribute name must be string not bytes With bytes as attribute name pyldap raises type error https://fedorahosted.org/freeipa/ticket/4985 Reviewed-By: Christian Heimes Reviewed-By: Jan Cholasta --- diff --git a/ipaserver/plugins/ldap2.py b/ipaserver/plugins/ldap2.py index a04be38..25fbfb8 100644 --- a/ipaserver/plugins/ldap2.py +++ b/ipaserver/plugins/ldap2.py @@ -417,7 +417,7 @@ class ldap2(CrudBackend, LDAPClient): # update group entry try: with self.error_handler(): - modlist = [(a, self.encode(b), self.encode(c)) + modlist = [(a, b, self.encode(c)) for a, b, c in modlist] self.conn.modify_s(str(group_dn), modlist) except errors.DatabaseError: