Dear List,

Using Postfix 2.4.6.
Finally resolved a problem that has been laying around for a while, just want 
to verify if this is the correct solution...

We have a canonical.regexp:

/us...@.*\.subdomain\.com/           [email protected]

main.cf:

canonical_maps = hash:/usr/local/postfix/etc/canonical
             regexp:/usr/local/postfix/etc/canonical.regexp
canonical_classes = envelope_sender, header_sender, header_recipient

Mails from internal application servers, are relayed over our smarthosts and 
send mail as [email protected] for cleanlyness we want this to show-up 
in outlook as [email protected] so users can make simple outlook rules. 

Now all mails that where generated on the smarthosts themselves are properly 
rewritten, but mails from the application servers still showup as 
[email protected].

Reading the canonical man page again I noticed: 

NOTE:  Postfix  versions  2.2  and  later  rewrite  message  headers  from  
remote  SMTP  clients  only  if  the  client  matches  the
       local_header_rewrite_clients parameter, or if the 
remote_header_rewrite_domain configuration parameter specifies a non-empty 
value. To
       get the behavior before Postfix 2.2, specify 
"local_header_rewrite_clients = static:all".

Now local_header_rewrite_clients wasn't defined so defaulted to 
permit_inet_interfaces, which I guess explains why it does work for mail 
generated on the smarthosts but not on 'clients'?
Changed this parameter to local_header_rewrite_clients = static:all, now 
rewriting works, but I'm not sure if this is the recommended way....

Thanks for any tips!

- 
Marco van Kammen
Springer Science+Business Media
System Manager & Postmaster 
- 
van Godewijckstraat 30 | 3311 GX
Office Number: 05E21 
Dordrecht | The Netherlands 
-  
tel 
 +31(78)6576446
fax 
 +31(78)6576302

- 
www.springeronline.com 
www.springer.com
- 



Reply via email to