Lmtp w/ Postfix and LDAP: change mailbox name when saving mail.
kbah at linuxmail.org
Tue Jan 20 13:12:33 EST 2009
On my LDAP server, the uid field of each user (person) is: "username~domain.org".
I correctly set up cyrus and saslauthd to authenticate with the username as the LDAP field above. A simple Horde hook does the job to make "user at whatever domain he/she typed" into "user~whatever domain...".
When authenticating, if the mailbox does not exist it gets created (autocreatequota is nonzero on imapd.conf). The mailbox is created following that naming convention (username~domain..).
createonpost is set to 1 on imapd.conf
My problem is when saving incoming mail. The mailbox "username~domain.org" is not created, instead it creates a mailbox named "username" (actually user/username, and "username~domain.org" is actually "user/username~domain.org"). Other relevant (I think) options from imapd.conf:
Only /etc/saslauthd.conf contains stuff about LDAP. I tried setting ldap_* options on imapd.conf (as the imapd.conf man page tells) but I guess they are not read when mail is arriving to the system (Postfix/Cyrus lmtp).
Is it possible to (automatically) create mailboxes with that naming convention? I want cyrus to save mail to "username~domain.org" instead of "username".
thanks in advance
Retail-Man Point of Sale (POS) Software
Low cost POS systems use Retail-Man software. Free 30 day evaluation.
Powered by Outblaze
More information about the Info-cyrus