summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--conf/templates/header_checks.template.in18
-rw-r--r--conf/templates/main.cf.template.in7
2 files changed, 25 insertions, 0 deletions
diff --git a/conf/templates/header_checks.template.in b/conf/templates/header_checks.template.in
new file mode 100644
index 0000000..e6d7220
--- /dev/null
+++ b/conf/templates/header_checks.template.in
@@ -0,0 +1,18 @@
+KOLAB_META_START
+TARGET=@emailserver_confdir@/header_checks
+PERMISSIONS=0640
+OWNERSHIP=@emailserver_tables_usr@:@emailserver_grp@
+KOLAB_META_END
+# this file is automatically written by the Kolab config backend
+# manual additions are lost unless made to the template in the Kolab config
+# directory
+# The template is @sysconfdir@/kolab/templates/header_checks.template
+
+# Cyrus does not like empty Message-Id: headers, see kolab/issue2350
+/^Message-Id:[[:space:]]*$/ IGNORE
+
+# Do not allow receiving mails which are already marked as read, flagged, etc.
+/^Status:/ IGNORE
+/^X-Status:/ IGNORE
+/^X-Label:/ IGNORE
+
diff --git a/conf/templates/main.cf.template.in b/conf/templates/main.cf.template.in
index ab3b78d..3270ceb 100644
--- a/conf/templates/main.cf.template.in
+++ b/conf/templates/main.cf.template.in
@@ -85,6 +85,13 @@ local_recipient_maps = $virtual_alias_maps, $alias_maps
# Don't parse and modify headers of message/rfc822 attachments
disable_mime_input_processing = yes
+# enable header_checks (not for attachment headers):
+header_checks = regexp:@emailserver_confdir@/header_checks
+# disable_mime_input_processing = yes already implies that attachment headers
+# are not being checked, but just to be sure:
+mime_header_checks =
+nested_header_checks =
+
## only use local_transport or a higher recipent_limit if issue825 is fixed
# local delivery, not using postfix local(8)
#local_transport = kolabmailboxfilter