[TriLUG] postfix addressing question -- resolution

Chris Merrill cmerrill at nc.rr.com
Thu Aug 21 09:45:55 EDT 2003


I got an answer to this question on the Postfix mailing
list, so I thought I'd repeat it here:

Starting somewhere in the 2.0 tree, Postfix adds the information
I needed (the address that a message was destined for, prior
to being 'de-aliased') is now contained in two places:
- a header is added to the message "X-Original-To" that contains
   the original address
- the original address is included in the mail log entry when the
   message is received: "orig_to=<me at domain.com>"

Chris

Chris Merrill wrote:
> A little background:
> I'm using the postfix aliases file as a sort of "whitelist" filter for
> spam.  All the aliases refer to a username that I have never given out.
> It's sorta the 'master' destination for my e-mail.
> Key to this scheme is that when I get spam, I look to see which address
> it came to and delete the alias.  Future messages to that address get
> bounced.
> 
> Of course, many spammers don't address the "To:" field correctly, so I was
> relying on the "Delivered-To:" field that is apparently added by Postfix.
> However, it seems to report the address _after_ it's been resolved against
> the alias file.  Even in the log file, it reports the resolved address,
> rather than the original address:
> 
> Aug  6 11:42:55 christophermerrill postfix/smtpd[9164]: connect from 
> ms-smtp-02.southeast.rr.com[24.93.67.83]
> Aug  6 11:42:55 christophermerrill postfix/smtpd[9164]: EE0DB73B78: 
> client=ms-smtp-02.southeast.rr.com[24.93.67.83]
> Aug  6 11:42:56 christophermerrill postfix/cleanup[9165]: EE0DB73B78: 
> message-id=<3F3120E4.8030908 at nc.rr.com>
> Aug  6 11:42:56 christophermerrill postfix/nqmgr[9101]: EE0DB73B78: 
> from=<cmerrill at nc.rr.com>, size=981, nrcpt=1 (queue active)
> Aug  6 11:42:56 christophermerrill postfix/smtpd[9164]: disconnect from 
> ms-smtp-02.southeast.rr.com[24.93.67.83]
> Aug  6 11:42:56 christophermerrill postfix/local[9169]: EE0DB73B78: 
> to=<hidden at christophermerrill.net>, relay=local, delay=1, status=sent 
> (mailbox)
> 
> 
> Does anyone know of a configuration setting to change this behavior?
> Or any other way to figure out who a message was originally destined for?
> 
> TIA,
> Chris
> 


-- 
*********************************
Chris Merrill
cmerrill at nc.rr.com
*********************************




More information about the TriLUG mailing list