[Dovecot] Use a different usename than the recipient address (that require a lookup)?

Mauricio Tavares raubvogel at gmail.com
Mon Nov 8 20:54:55 EET 2010


On 11/08/2010 01:42 PM, Zhou, Yan wrote:
> Hi there,
>
> I am integrating Postfix and DoveCot, both use LDAP to look up
> user/email address info. My question is this: can I create a user
> "jsmith" to get all emails with the recipient address:
> dovecotdemo at domain?  Because of using LDAP, I need to do a lookup to
> know that the user "jsmith" is getting emails for "dovecotdemo at domain",
> NOT "dovecotdemo" (there will be no such user).
>
	Most of my users just use their usernames as their mail directories. 
But, I have one I had to do something like

   userdb passwd-file {
      args = /etc/dovecot/users
   }

and then define in /etc/dovecot/users for that user where his maildir is.

Another option would be to use aliases in postfix.

> In postfix's master.cf, I can use LDA to deliver to DoveCot, which needs
> to know the user name where the message should be delivered to. But I
> would not know that at the time because I need to do a lookup in LDAP.
> Does the DoveCot delivery agent have any way to allow me return a
> different user name after LDAP lookup?
>
	If you use virtual domains, you could specify where the emails go using 
virtual_mailbox_maps.

> I would not want to modify a couple of files to accomplish that, because
> I would have to do that for every email address created.
>
	Why?

> Thanks,
> Yan
>
> NOTICE: This email message is for the sole use of the intended recipient(s)
>   and may contain confidential and privileged information. Any unauthorized
>   review, use, disclosure or distribution is prohibited. If you are not the
>   intended recipient, please contact the sender by reply email and destroy all
>   copies of the original message.
>
> This message has been content scanned by the Axway MailGate.
> MailGate uses policy enforcement to scan for known viruses, spam, undesirable content and malicious code. For more information on Axway products please visit www.axway.com.



More information about the dovecot mailing list