]> www.infradead.org Git - users/dwmw2/eximconf.git/commitdiff
Immediate reject for HTML to mailing lists
authorDavid Woodhouse <David.Woodhouse@intel.com>
Fri, 5 Apr 2013 13:08:06 +0000 (14:08 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Fri, 5 Apr 2013 13:08:06 +0000 (14:08 +0100)
include/acl-content
include/acl-mime
include/acl-recipient

index b84af4dda16994da1fd794fa1901c6677d5c3a85..05c22a7577f4769447c3862defdfdf998fd7f2ec 100644 (file)
@@ -156,6 +156,13 @@ check_content:
   warn dnslists = list.dnswl.org
        set acl_m_greylistreasons =
 
+  deny condition = ${if and {
+                        {eq{$acl_m_tolists}{yes}} \
+                        {eq{$acl_m_tonotlists}{}} \
+                       {eq{$acl_ishtml}{yes}}
+                       } {1}}
+       message = Mailing lists do not accept HTML mail. See http://david.woodhou.se/email.html
+
   # Now, call the greylisting code. It'll do its thing if 
   # $acl_m_greylistreasons is set to indicate that there was something 
   # suspicious about the message.
index 3c4b9c5c723f3bf9ef109c2e9cf7f5c6e3b2d01d..4e7cb3353ba1daadd134677f2264559525346975 100644 (file)
@@ -14,6 +14,7 @@ check_mime:
   warn !condition = $mime_is_rfc822
        condition = $mime_is_coverletter
        condition = ${if eq{$mime_content_type}{text/html} {1}}
+       set acl_m_ishtml = yes
        set acl_m_greylistreasons = Message appears to have HTML content, not just plain text.\n$acl_m_greylistreasons
 
   accept
index 6f792350cd12614447db7692985f24fd4ee8bb4b..27994215bf056081f1e77e54bb2786329489b19c 100644 (file)
@@ -138,4 +138,9 @@ check_recipient:
           !senders     = @@lsearch;CONFDIR/conf/verify-except-senders
            !verify     = sender/callout=120s,random
 
+  warn    domains      = lists.infradead.org
+           set acl_m_tolists = yes
+  warn     !domains      = lists.infradead.org
+           set acl_m_tonotlists = yes
+
   accept