Bug 57090 - migrate-fetchmail does not distinguish between template and user objects
migrate-fetchmail does not distinguish between template and user objects
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Mail
UCS 5.0
Other Linux
: P5 normal (vote)
: UCS 5.0-6-errata
Assigned To: Juan Carlos
Christian Castens
https://git.knut.univention.de/univen...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2024-02-27 09:21 CET by Finn David
Modified: 2024-03-07 13:07 CET (History)
1 user (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 4: Minor Usability: Impairs usability in secondary scenarios
Who will be affected by this bug?: 3: Will affect average number of installed domains
How will those affected feel about the bug?: 2: A Pain – users won’t like this once they notice it
User Pain: 0.137
Enterprise Customer affected?: Yes
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number: 2023121121000124
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Finn David univentionstaff 2024-02-27 09:21:34 CET
The join script 92univention-fetchmail.inst failed because the migration script /usr/share/univention-fetchmail/migrate-fetchmail.py tried to process objects that are templates which don't have a uid.

The following change in line 147 was needed to make it work:

#filter='(objectClass=univentionFetchmail)',                                                                                                               filter='(&(objectClass=univentionFetchmail)(uid=*))',
Comment 1 Finn David univentionstaff 2024-02-27 09:35:26 CET
This was the traceback:

Traceback (most recent call last):
  File "/usr/share/univention-fetchmail/migrate-fetchmail.py", line 195, in <module>
    main()
  File "/usr/share/univention-fetchmail/migrate-fetchmail.py", line 190, in main
    c.main()
  File "/usr/share/univention-fetchmail/migrate-fetchmail.py", line 110, in main
    ret = self.convert()
  File "/usr/share/univention-fetchmail/migrate-fetchmail.py", line 140, in convert
    uid = attrs['uid'][0].decode('UTF-8')
KeyError: 'uid'
Comment 2 Juan Carlos univentionstaff 2024-03-04 12:19:45 CET
Changes:

Only process user objects in migrate-fetchmail.py

Package:

Package: univention-fetchmail
Version: 13.0.8-2
Branch: ucs_5.0-0
Scope: errata5.0-6

Commits:

56d2f8076b679cc59a4209424397620d54645054
Comment 3 Christian Castens univentionstaff 2024-03-04 12:41:39 CET
QA:
  advisories: OK
  "/usr/share/univention-fetchmail/migrate-fetchmail.py" only processes objects that are of the object type "users/user" (and of objectClass "univentionFetchmail"): OK

Waiting for the overnight test run
Comment 4 Christian Castens univentionstaff 2024-03-05 12:03:09 CET
QA:
  no related errors in the overnight test run: OK