Zhou, Yan
2010-Nov-08 18:42 UTC
[Dovecot] Use a different usename than the recipient address (that require a lookup)?
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). 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? 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. 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.
Mauricio Tavares
2010-Nov-08 18:54 UTC
[Dovecot] Use a different usename than the recipient address (that require a lookup)?
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.
Timo Sirainen
2010-Nov-26 18:27 UTC
[Dovecot] Use a different usename than the recipient address (that require a lookup)?
On Mon, 2010-11-08 at 13:42 -0500, Zhou, Yan wrote:> 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).If there is e.g. "mail" field that contains "dovecotdemo at domain" value, you could set for example: user_attrs = uid=user, (other attributes) user_filter = (|(uid=%u)(mail=%u))