From 77237db343d859476da6393ca1a80c2eec8a81a8 Mon Sep 17 00:00:00 2001 From: Andrew Aitchison Date: Fri, 21 Oct 2022 13:00:37 +0100 Subject: [PATCH 1/1] De-tainting mailman configuration. Bug 2905 --- templates/web/howto/mailman21.xsl | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/templates/web/howto/mailman21.xsl b/templates/web/howto/mailman21.xsl index 66ce436..a5d29ed 100644 --- a/templates/web/howto/mailman21.xsl +++ b/templates/web/howto/mailman21.xsl @@ -160,8 +160,10 @@ domainlist mm_domains=list.example.com MM_WRAP=MM_HOME/mail/mailman # # The path of the list config file (used as a required file when -# verifying list addresses) -MM_LISTCHK=MM_HOME/lists/${lc::$local_part}/config.pck +# verifying list addresses). The option used takes a list +# which is list-split before string-expansion, so we change the +# default list-separator. +MM_LISTCHK=<@ MM_HOME/lists/${lc:$local_part}/config.pck

Exim Router

@@ -172,6 +174,7 @@ MM_LISTCHK=MM_HOME/lists/${lc::$local_part}/config.pck
mailman_router:
   driver            = accept
   domains           = +mm_domains
+  local_parts       = dsearch,filter=dir;MM_HOME/lists
   require_files     = MM_LISTCHK
   local_part_suffix_optional
   local_part_suffix = -admin     : \
@@ -196,7 +199,7 @@ MM_LISTCHK=MM_HOME/lists/${lc::$local_part}/config.pck
'${if def:local_part_suffix \ {${sg{$local_part_suffix}{-(\\w+)(\\+.*)?}{\$1}}} \ {post}}' \ - $local_part + $local_part_data current_directory = MM_HOME home_directory = MM_HOME user = MM_UID @@ -336,7 +339,7 @@ VERP_DELIVERY_INTERVAL = 0

In this case, you must change the MM_HOME macro to something like this:-

-
MM_HOME=/virtual/${lc::$domain}/mailman
+
MM_HOME=/virtual/${lc:$domain_data}/mailman

and modify the mm_domains domain list appropriately.

-- 2.30.2