On 2009-09-27 Erick Calder wrote:
> On Sep 27, 2009, at 1:03 PM, LuKreme wrote:
>> On Sep 27, 2009, at 2:52 AM, Erick Calder wrote:
>>> On Sep 27, 2009, at 12:53 AM, LuKreme wrote:
>>>> On Sep 27, 2009, at 0:53, Erick Calder <e...@arix.com> wrote:
>>>>>  if the message were for no-ex...@arix.com then it gets rerouted  
>>>>> to n...@arix.com which also doesn't exist and therefor bounces.
>>>>
>>>> Yes, it bounces. This makes you a backacatter source. This is bad.
>>>
>>> but doesn't my postfix server bounce by default when receiving a mail 
>>> for an inexistent address? and if it doesn't, how are users who 
>>> misspell my address to know their message didn't get delivered?
>>
>> No, not generally. Unknown users are REJECTed, not bounced.
>
> ok, I'm not getting this.  your statements of 12:53AM and of 1:03PM
> seem contradictory... if an address doesn't exist, does it get bounced
> (as stated on 12:53AM) or rejected (as stated on 1:03PM, in which case
> I'm _not_ a backscatter source, and with which Ansgar and mouss seem
> to agree)?

You're just misunderstanding how virtual alias maps work.

During the SMTP dialog Postfix checks its various recipient/relay maps
for valid recipients. If a valid match is found, the mail is accepted
and queued for further relaying. However, Postfix does not expand the
virtual alias maps at this point. If you have a match on the left side
of your virtual aliases, Postfix does not check whether the
corresponding right side entry actually is valid.

Basically the process goes like this:

- Sending MTA starts SMTP dialog, giving no-ex...@arix.com as the RCPT
  TO address
- Postfix finds mapping no-ex...@arix.com -> n...@arix.com in its virtual
  alias maps
- Postfix accepts the mail and queues it for further delivery, because a
  valid mapping exists
- Next Postfix tries to relay the already accepted mail to n...@arix.com,
  which is rejected, becaus n...@arix.com doesn't exist
- Postfix thus finds itself unable to deliver the mail accepted for
  no-ex...@arix.com, and thus (as per RFC 2821) MUST generate a bounce

That's why you want to accept mail only for valid addresses.

Regards
Ansgar Wiechers
-- 
"Abstractions save us time working, but they don't save us time learning."
--Joel Spolsky

Reply via email to