| |||||||||||||||||||||||||||||||
|
> Hi, I'm using Postfix 2.2.10, but I hope this would be the same in > newer versions. > I have 2 tables with aliases in pgsql. First for mail adress aliases > and one for domain aliases - this shlould be OK. > The domains are aliased as follows (lookup configured in > alias_domains_maps.cf): > > @ourdomain2.cz @ourdomain1.cz > @ourdomain3.cz @ourdomain1.cz > ... These are called wildcard aliases (all users in a domain get redirected to the same user in another). > > When I send an email to a nonexistent mailbox, for example > nonexistent, it is rejected just on the rcpt to in the > smtp. Works great. But when I sent an email to a nonexistent mailbox > in aliased domain, for example nonexistent, it is > accepted via 25 port into postfix and then is bounced with > "status=bounced (unknown user: "nonexistent")". Why this > is not rejected just on rcpt like when sending to > nonexistent? http://www.postfix.org/virtual.5.html says: Note: @/domain/ is a wild-card. With this form, the Postfix SMTP server accepts mail for any recipient in /domain/, regardless of whether that recipient exists. This may turn your mail system into a backscatter source: Postfix first accepts mail for non-existent recipients and then tries to return that mail as "undeliverable" to the often forged sender address. do you see the "accepts mail for any recipient"? replace your wildcard aliases with per-user aliases. do this with sql statements: only return a result if the "target" user exists in the virtual mailbox table. this assumes you have a one depeth (recursion) level alias system. implementing it with any depth level (foo1 => foo2 => foo3 => ...) is harder. > > My user alias accounts looks like this (lookup configured in > alias_mailbox_maps.cf): > user2 user1 > user3 user1 > ... > > And my account map (lookup configured in virtual_mailbox_maps.cf): > user1 /var/accounts/user1 > user2 /var/account/user2 > > What I'm doing wrong? I cannot find the problem from most debugging > output, the same like from the virtual(5) doc. > > This is my configuration: > ------------------------- > virtual_mailbox_domains = ourdomain1.cz > > virtual_alias_maps = pgsql:/etc/postfix/pgsql/alias_domains_maps.cf > pgsql:/etc/postfix/pgsql/alias_mailbox_maps.cf > > virtual_mailbox_maps = > pgsql:/etc/postfix/pgsql/virtual_mailbox_maps.cf > > Can anyone help me please. Many thanks > Tomas > >
| ||||||||||||||||||||||||||||||
© 2004-2008 readlist.com