mailman: set SUBSCRIBE_FORM_SECRET to protect better against spammers
authorRalf Jung <post@ralfj.de>
Sat, 2 Jun 2018 13:49:21 +0000 (15:49 +0200)
committerRalf Jung <post@ralfj.de>
Sat, 2 Jun 2018 13:49:21 +0000 (15:49 +0200)
host_vars/template.yml
roles/email/templates/mm_cfg.py

index ab4b23a..fb971ba 100644 (file)
@@ -51,6 +51,7 @@ postfix:
     domains: # the file /etc/postfix/virtual_alias_map can be used to configure aliases
     - lists.example.org
     default_footer: "-- \n%(list_name)s@%(host_name)s - %(description)s\nConfiguration: %(web_page_url)slistinfo%(cgiext)s/%(list_name)s\nUnsubscribe: %(list_name)s-unsubscribe@%(host_name)s\n"
+    form_secret: $RANDOM
   # optional: Install and configure dovecot
   dovecot:
     domains: # the file /etc/postfix/virtual_alias_map can be used to configure aliases
index a3b02f9..9464272 100644 (file)
@@ -128,3 +128,6 @@ DEFAULT_DIGEST_FOOTER = DEFAULT_MSG_FOOTER
 # DMARC, DKIM-compatibility
 REMOVE_DKIM_HEADERS = 1 # remove DKIM headers for lists where From: is changed
 DEFAULT_DMARC_MODERATION_ACTION = 1 # Munge From
+
+# Spammer protection
+SUBSCRIBE_FORM_SECRET = "{{postfix.mailman.form_secret}}"