On 12/27/2010 4:14 PM, Roman Gelfand wrote:
I am trying to strip some lines from outgoing mail header. It doesn't
work for me. I am not sure what I am doing wrong.
master.cf
-o header_checks=pcre:header_checks.pcre
Your error report is a little light on details... It would be
nice if you had mentioned where in master.cf you put this.
But never mind.
The header_checks parameter is a property of cleanup, not of
smtp or smtpd. To use alternate header_checks, you need to
define a different cleanup service for smtpd.
But that's probably not what you want anyway. To remove
headers on output, use smtp_header_checks on the smtp
transport (requires postfix 2.5 or newer).
http://www.postfix.org/postconf.5.html#smtp_header_checks
You also should specify the full path to the header checks
file you use.
# master.cf
smtp unix ... smtp
-o smtp_header_checks=pcre:/path/to/smtp_header_checks.pcre
-- Noel Jones