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 ab4b23afd9a231ff26c764ba23cab912d5c27229..fb971bae652e0a7f4529bbb674b74e7636e3beac 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 a3b02f948504816cd27dbc590987fb5f9d80ff17..94642721363260896b90053b27827cabd252a929 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}}"