From b12e0addc0341b5e33acd08610205c4752bf097e Mon Sep 17 00:00:00 2001 From: andryyy Date: Sat, 25 Mar 2017 18:18:14 +0100 Subject: [PATCH 1/3] Re-add anonymize headers section --- docs/u_and_e.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/docs/u_and_e.md b/docs/u_and_e.md index f348efee..d0a52cc8 100644 --- a/docs/u_and_e.md +++ b/docs/u_and_e.md @@ -15,6 +15,25 @@ mailcow UI configuration parameters can be to... \* To change SOGos default language, you will need to edit `data/conf/sogo/sogo.conf` and replace "English" by your preferred language. +## Anonymize headers + +Save as `data/conf/postfix/mailcow_anonymize_headers.pcre`: + +``` +/^\s*Received:[^\)]+\)\s+\(Authenticated sender:(.+)/ + REPLACE Received: from localhost (localhost [127.0.0.1]) (Authenticated sender:$1 +/^\s*User-Agent/ IGNORE +/^\s*X-Enigmail/ IGNORE +/^\s*X-Mailer/ IGNORE +/^\s*X-Originating-IP/ IGNORE +/^\s*X-Forward/ IGNORE +``` + +Add this to `data/conf/postfix/main.cf`: +``` +smtp_header_checks = pcre:/opt/postfix/conf/mailcow_anonymize_headers.pcre +``` + ## Backup and restore maildir (simple tar file) ### Backup From d5c8f0160cfe6297a0947a324d8d8a375e18e532 Mon Sep 17 00:00:00 2001 From: andryyy Date: Sun, 26 Mar 2017 11:07:50 +0200 Subject: [PATCH 2/3] Go back to apt-stable repo --- data/Dockerfiles/rspamd/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data/Dockerfiles/rspamd/Dockerfile b/data/Dockerfiles/rspamd/Dockerfile index 8d0a7f0a..70a0bbab 100644 --- a/data/Dockerfiles/rspamd/Dockerfile +++ b/data/Dockerfiles/rspamd/Dockerfile @@ -9,8 +9,8 @@ RUN dpkg-divert --local --rename --add /sbin/initctl \ && dpkg-divert --local --rename --add /usr/bin/ischroot \ && ln -sf /bin/true /usr/bin/ischroot -RUN apt-key adv --fetch-keys http://rspamd.com/apt/gpg.key \ - && echo "deb http://rspamd.com/apt/ xenial main" > /etc/apt/sources.list.d/rspamd.list \ +RUN apt-key adv --fetch-keys http://rspamd.com/apt-stable/gpg.key \ + && echo "deb http://rspamd.com/apt-stable/ xenial main" > /etc/apt/sources.list.d/rspamd.list \ && apt-get update \ && apt-get -y install rspamd ca-certificates python-pip From 60fa9ab9ddf9f8163f6254dbbc7874618e22b350 Mon Sep 17 00:00:00 2001 From: andryyy Date: Sun, 26 Mar 2017 11:08:07 +0200 Subject: [PATCH 3/3] Fall back to dkim.conf --- data/conf/rspamd/local.d/dkim.conf | 34 +++++++++++++++++++ data/conf/rspamd/local.d/dkim_signing.conf | 38 ---------------------- 2 files changed, 34 insertions(+), 38 deletions(-) create mode 100644 data/conf/rspamd/local.d/dkim.conf delete mode 100644 data/conf/rspamd/local.d/dkim_signing.conf diff --git a/data/conf/rspamd/local.d/dkim.conf b/data/conf/rspamd/local.d/dkim.conf new file mode 100644 index 00000000..c199c6ae --- /dev/null +++ b/data/conf/rspamd/local.d/dkim.conf @@ -0,0 +1,34 @@ +sign_condition =<