Univention Bugzilla – Bug 41745
univention.admin.uldap doesn't set self.binddn when calling bind manually
Last modified: 2017-04-04 18:29:36 CEST
>>> import univention.admin.uldap >>> lo = univention.admin.uldap.access(base='dc=foo') >>> lo.bind('uid=Administrator,cn=users,dc=foo', 'univention') >>> lo.binddn '' If given via __init__(binddn=foo, bindpw=bar) they are stored. Otherwise not. This might have several side effects! In UCS@school lo.binddn is used.
Created attachment 7789 [details] patch
Created attachment 7801 [details] patch Updated patch. There are several broken places. This currently causes that the joining windows clients into a UCS@school domain they are created in a random school - if the LDAP entries weren't created before.
The alternative to fix this is fixing Bug #41765 by adding "-o school=$OU" to the create_windows_computer call in univention_samaccountname_ldap_check.c. This bug should be fixed nevertheless so that lo.binddn can be used by scripts.
Created attachment 7810 [details] patch Make binddn a property in univention.uldap.access which points to the univention.access.binddn attribute. The other files in the patches are unnecessary then or part of Bug #41812, Bug #41811.
univention-directory-manager-modules (12.0.3-1): r72331 | Bug #41745: use binddn from parent access class
OK: r72331 OK: No ChangeLog OK: import univention.admin.uldap as l b = l.configRegistry['ldap/base'] lo = l.access(base=b) dn = 'uid=Administrator,cn=users,%s' % (b,) lo.bind(dn, 'univention') assert lo.binddn == dn assert lo.bindpw == 'univention' assert lo.host == 'localhost' assert lo.port == 7389 assert lo.base == b assert lo.start_tls == 2
UCS 4.2 has been released: https://docs.software-univention.de/release-notes-4.2-0-en.html https://docs.software-univention.de/release-notes-4.2-0-de.html If this error occurs again, please use "Clone This Bug".