I've configured my Zimbra system in this way:
- All local addresses are rewriten from firstname.lastname@example.org to email@example.com with a smtp_generic_maps option in main.cf
- The mail is fetched from the ISP with fetchmail:
Everything works as expected: users can send mail as firstname.lastname@example.org and receive mail as email@example.com. Local mail between firstname.lastname@example.org and email@example.com works well.
poll pop3.isp.com user firstname.lastname@example.org with password pass is email@example.com
The problem starts when the AS/AV option is started:
- Local users can send mails
- Local users don't receive mails fetched from fetchmail because amavisd gets the MX record of the rewrited address (firstname.lastname@example.org) as the relay.
How can I tell amavis to not relay some addresses and deliver locally? Is it possible to rewrite the recipient address before scanning/antispamming?