I very successfully dealt with single line headers in pcre:/etc/postfix/header_check
. But when it comes to multi-lines, I'm a bit frustrated. Here is a part of header:
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
Content-Type: multipart/alternative;
boundary="_000_8FA6C259529CB0418FBDF96A6B22A486209F15MAILmynetworkloca_"
MIME-Version: 1.0
--_000_8FA6C259529CB0418FBDF96A6B22A486209F15MAILmynetworkloca_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
test
--_000_8FA6C259529CB0418FBDF96A6B22A486209F15MAILmynetworkloca_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
And what I need, just to get rid of strings like
--_000_8FA6C259529CB0418FBDF96A6B22A486209F15MAILmynetworkloca_
Or at least replace last part MAILmynetworkloca_
to something like maildomaincom_
I've tried to put to my /etc/postfix/header_check
/MAILmynetworkloca_/ REPLACE maildomaincom_
but it didn't work