Bug 57733 - Fix dynamic syntax UDM filter
Summary: Fix dynamic syntax UDM filter
Status: CLOSED FIXED
Alias: None
Product: UCS
Classification: Unclassified
Component: UDM (Generic)
Version: UCS 5.0
Hardware: Other Linux
: P5 normal
Target Milestone: UCS 5.0-9-errata
Assignee: Felix Botner
QA Contact: Johannes Königer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-11-07 10:33 CET by Felix Botner
Modified: 2025-03-21 10:32 CET (History)
2 users (show)

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Customer ID:
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Comment 1 Daniel Tröder univentionstaff 2024-11-07 10:50:04 CET
Until we have migrated to Gitlab, please put the tracebacks here, so it can be found by support and others.

-------

Internal server error during "udm/syntax/choices (REDACTED)".
Request: udm/syntax/choices (REDACTED)
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/univention/management/console/modules/decorators.py", line 259, in _run
    result = self._function(*args, **kwargs)  # type: Union[BaseException, _T]
  File "/usr/lib/python3/dist-packages/univention/management/console/modules/udm/udm_ldap.py", line 115, in _decorated
    return method(*args, **kwargs)
  File "/usr/lib/python3/dist-packages/univention/management/console/ldap.py", line 203, in _decorated
    result = func(*args, **kwargs)
  File "/usr/lib/python3/dist-packages/univention/management/console/modules/udm/__init__.py", line 1036, in syntax_choices
    return read_syntax_choices(syntax, options, ldap_connection=ldap_connection, ldap_position=ldap_position)
  File "/usr/lib/python3/dist-packages/univention/management/console/modules/udm/udm_ldap.py", line 1383, in read_syntax_choices
    choices = syn.get_choices(ldap_connection, options)
  File "/usr/lib/python3/dist-packages/univention/admin/syntax.py", line 1011, in get_choices
    filter_s = cls._create_ldap_filter(options, module)
  File "/usr/lib/python3/dist-packages/univention/admin/syntax.py", line 675, in _create_ldap_filter
    filter_s = cls.udm_filter % _EscapedDict(options)
  File "/usr/lib/python3/dist-packages/univention/admin/syntax.py", line 7093, in __missing__
    return escape_filter_chars(self._dict[key], 0)
KeyError: 'siteUMC'


> The error happens during opening the UDM module REDACTED via UMC. Handling mailboxes on the CMDline is fine, no issues there.

> I also found out, that we don't use --udm_syntax during the LDAP schema registration with ucs_registerLDAPExtension, that's why our custom syntax isn't available via settings/udm_syntax list
Comment 3 Felix Botner univentionstaff 2024-11-07 10:53:44 CET
yep, thanks, you are right
Comment 4 Felix Botner univentionstaff 2024-11-11 15:04:16 CET
5.0-9 01731338a710f1e0e20d9d38938a42cf597923df

Successful build
Package: univention-directory-manager-modules
Version: 15.0.28-7
Branch: 5.0-0
Scope: errata5.0-9

5.1-0 2cc0ca65eadf581c7bb7cbcbbd6245b63a45bb59

Successful build
Package: univention-directory-manager-modules
Version: 16.0.29
Branch: 5.1-0

5.2-0 e6525297334acd8531ca53031cab1980c8592fe3

Successful build
Package: univention-directory-manager-modules
Version: 17.0.24
Branch: 5.2-0
Comment 5 Johannes Königer univentionstaff 2024-11-12 12:24:54 CET
Package has been built and tests runs have not shown any related test failures.
Comment 6 Christian Castens univentionstaff 2024-11-13 17:21:58 CET
<https://errata.software-univention.de/#/?erratum=5.0x1171>