Bug 24449 - [Cyrus] Anmeldung mit UID nicht über loopback möglich.
[Cyrus] Anmeldung mit UID nicht über loopback möglich.
Status: RESOLVED INVALID
Product: UCS
Classification: Unclassified
Component: Mail
UCS 3.0
Other Linux
: P5 normal (vote)
: ---
Assigned To: Bugzilla Mailingliste
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-11-08 16:04 CET by Janek Walkenhorst
Modified: 2013-11-19 12:18 CET (History)
1 user (show)

See Also:
What kind of report is it?: ---
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):
Max CVSS v3 score:


Attachments
Skript zum Testen von IMAP-Servern (898 bytes, text/plain)
2011-11-08 16:04 CET, Janek Walkenhorst
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Janek Walkenhorst univentionstaff 2011-11-08 16:04:17 CET
Created attachment 3761 [details]
Skript zum Testen von IMAP-Servern

Wenn sich mit UID über die loopback-Schnittstellen oder die Link-local-Adresse
an Cyrus angemeldet wird, funktioniert das Auswählen der INBOX nicht:

# ./imaptest.py tester univention fe80::20c:29ff:feb0:b271%eth0 ::1 127.0.0.1
FAILED imaplib.IMAP4 fe80::20c:29ff:feb0:b271%eth0 ('NO', ['Mailbox does not
exist'])
FAILED imaplib.IMAP4_SSL fe80::20c:29ff:feb0:b271%eth0 ('NO', ['Mailbox does
not exist'])
FAILED imaplib.IMAP4 ::1 ('NO', ['Mailbox does not exist'])
FAILED imaplib.IMAP4_SSL ::1 ('NO', ['Mailbox does not exist'])
FAILED imaplib.IMAP4 127.0.0.1 ('NO', ['Mailbox does not exist'])
FAILED imaplib.IMAP4_SSL 127.0.0.1 ('NO', ['Mailbox does not exist'])

Mit der E-Mail-Adresse funktioniert es:

# ./imaptest.py tester@janek.test univention fe80::20c:29ff:feb0:b271%eth0 ::1
127.0.0.1
OK imaplib.IMAP4 fe80::20c:29ff:feb0:b271%eth0
OK imaplib.IMAP4_SSL fe80::20c:29ff:feb0:b271%eth0
OK imaplib.IMAP4 ::1
OK imaplib.IMAP4_SSL ::1
OK imaplib.IMAP4 127.0.0.1
OK imaplib.IMAP4_SSL 127.0.0.1

Über normale IPv6-Adressen oder den Hostnamen (hat nur einen AAAA-Record)
funktioniert es auch mit UID ohne Probleme:
# ./imaptest.py tester univention qa300 2001:4dd0:ff00:8c42:ff12::30
2001:4dd0:ff00:8c42:ff12::1338
OK imaplib.IMAP4 qa300
OK imaplib.IMAP4_SSL qa300
OK imaplib.IMAP4 2001:4dd0:ff00:8c42:ff12::30
OK imaplib.IMAP4_SSL 2001:4dd0:ff00:8c42:ff12::30
OK imaplib.IMAP4 2001:4dd0:ff00:8c42:ff12::1338
OK imaplib.IMAP4_SSL 2001:4dd0:ff00:8c42:ff12::1338
Comment 1 Janek Walkenhorst univentionstaff 2011-11-08 16:12:09 CET
>>> a=imaplib.IMAP4('localhost')
>>> a.login('tester@janek.test', 'univention')
>>> a.list()
('OK', [
 '(\\HasChildren) "/" INBOX',
 '(\\HasNoChildren) "/" INBOX/Ham',
 '(\\HasNoChildren) "/" INBOX/Spam'
 ]
)

>>> a=imaplib.IMAP4('localhost')
>>> a.login('tester', 'univention')
>>> a.list()
('OK', [
 None
 ]
)
Comment 2 Felix Botner univentionstaff 2013-11-19 12:18:49 CET
-> cyradm --user test1 10.200.7.70

->  /var/log/auth.log
Nov 19 12:16:40 pmaster PAM-univentionmailcyrus[11168]: No or ambigous result, found 0 entries.
Nov 19 12:16:40 pmaster PAM-univentionmailcyrus[11168]: failed to map username

-> /etc/pam.d/imap
...
auth requisite pam_univentionmailcyrus.so ...
...

IMAP login is only possible with the mailPrimaryAddress, not with the uid