1

I run a small mail service that currently supports a few hundred users. When someone sends mail and someone looks at the source, the persons real IP is contained in, IIRC X-Originating-IP. For user privacy, I don't want their real IP to be displayed anywhere in the headers. I know this can be done as I believe most of the major webmail services do it. Is there a way to do it in Postfix for SMTP?

Thanks

3

Add the following to your /etc/postfix/main.cf:

mime_header_checks = regexp:/etc/postfix/header_checks
header_checks = regexp:/etc/postfix/header_checks

and then put the following into /etc/postfix/header_checks:

/^Received:.*with ESMTPSA/      IGNORE
/^X-Originating-IP:/            IGNORE
/^X-Mailer:/                    IGNORE
/^Mime-Version:/                IGNORE
/^User-Agent:/                  IGNORE

Don't forget to postmap this file and then reload Postfix.

(Note: It's clear this will hide even more stuff. Adapt as necessary).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.