Univention Bugzilla – Bug 52541
Opening samba domain object in the LDAP browser in UMC always shows popup
Last modified: 2023-04-11 14:25:35 CEST
When opening the samba domain object in the LDAP browser in UMC, a popup is shown: ==================================================================================== Notification The following empty properties were set to default values in the form. These values will be applied when saving. General - Password - Passwords must meet complexity requirements: true General - General Samba domain settings - Next RID: 1000 General - Password - Store plaintext passwords: false ==================================================================================== Clicking on "ok" and "save" fixes the "Next RID" value but doesn't change anything else and the popup comes up again when reopening the Samba domain object. Manually changing the Defaults to the opposite doesn't make the message go away either. UCS 4.4-7 errata829 (till 850) but already reproducable at least in 4.3-1 e229. The problem doesn't show with 4.2-5 e630, so it's a regression.
I tried this, but did not work: root@primary:~ # python3 Python 3.7.3 (default, Oct 31 2022, 14:04:00) [GCC 8.3.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import univention.admin.modules as modules >>> from univention.admin.uldap import getAdminConnection >>> FILTER_STRING = '' >>> modules.update() >>> lo, po = getAdminConnection() >>> settings_mod = modules.get('settings/sambadomain') >>> modules.init(lo, po, settings_mod) >>> settings = settings_mod.lookup(None, lo, FILTER_STRING) >>> for setting in settings: ... setting.open() ... print("Setting default values for setting '{}".format(setting['name'])) ... setting.set_defaults = 1 ... setting.set_default_values() ... setting.modify() ... Setting default values for setting 'SCHEIN Traceback (most recent call last): File "/usr/lib/python3/dist-packages/univention/admin/uldap.py", line 807, in modify return self.lo.modify(dn, changes, serverctrls=serverctrls, response=response, rename_callback=rename_callback) File "/usr/lib/python3/dist-packages/univention/uldap.py", line 211, in _decorated return func(self, *args, **kwargs) File "/usr/lib/python3/dist-packages/univention/uldap.py", line 766, in modify self.modify_ext_s(dn, ml, serverctrls=serverctrls, response=response) File "/usr/lib/python3/dist-packages/univention/uldap.py", line 211, in _decorated return func(self, *args, **kwargs) File "/usr/lib/python3/dist-packages/univention/uldap.py", line 825, in modify_ext_s rtype, rdata, rmsgid, resp_ctrls = self.lo.modify_ext_s(dn, ml, serverctrls=serverctrls) File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 1253, in modify_ext_s return self._apply_method_s(SimpleLDAPObject.modify_ext_s,*args,**kwargs) File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 1197, in _apply_method_s return func(self,*args,**kwargs) File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 602, in modify_ext_s resp_type, resp_data, resp_msgid, resp_ctrls = self.result3(msgid,all=1,timeout=self.timeout) File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 749, in result3 resp_ctrl_classes=resp_ctrl_classes File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 756, in result4 ldap_result = self._ldap_call(self._l.result4,msgid,all,timeout,add_ctrls,add_intermediates,add_extop) File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 329, in _ldap_call reraise(exc_type, exc_value, exc_traceback) File "/usr/lib/python3/dist-packages/ldap/compat.py", line 44, in reraise raise exc_value File "/usr/lib/python3/dist-packages/ldap/ldapobject.py", line 313, in _ldap_call result = func(*args,**kwargs) ldap.TYPE_OR_VALUE_EXISTS: {'desc': 'Type or value exists', 'info': 'modify/add: sambaNextRid: value #0 already exists'} During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 6, in <module> File "/usr/lib/python3/dist-packages/univention/admin/handlers/__init__.py", line 650, in modify dn = self._modify(modify_childs, ignore_license=ignore_license, response=response) File "/usr/lib/python3/dist-packages/univention/admin/handlers/__init__.py", line 1366, in _modify self.dn = self.lo.modify(self.dn, ml, ignore_license=ignore_license, serverctrls=serverctrls, response=response, rename_callback=wouldRename.on_rename) File "/usr/lib/python3/dist-packages/univention/admin/uldap.py", line 818, in modify raise univention.admin.uexceptions.ldapError(_err2str(msg), original_exception=msg) univention.admin.uexceptions.ldapError: LDAP Error: Type or value exists: modify/add: sambaNextRid: value #0 already exists. >>>