eximconf: reject messages that the sender says are spam
authorAdam D. Barratt <adam@adam-barratt.org.uk>
Sun, 27 Oct 2019 20:03:01 +0000 (20:03 +0000)
committerAdam D. Barratt <adam@adam-barratt.org.uk>
Sun, 27 Oct 2019 20:03:01 +0000 (20:03 +0000)
Signed-off-by: Adam D. Barratt <adam@adam-barratt.org.uk>
modules/exim/templates/eximconf.erb

index 7fe1b6d..da1b73f 100644 (file)
@@ -1020,6 +1020,10 @@ check_message:
   # header.  Take their crack pipe away.
   drop   condition = ${if match{${lc:$h_From:}}{\Npostmaster@([^.]+\.)?debian\.org\N}}
 
+  # If the sending system says the mail is spam, believe them
+  deny    condition = ${if eqi {$h_X-Spam-Status:}{YES}}
+          message   = Incoming spam flags
+
 <%- if @is_rtmaster -%>
   deny    condition = ${if eq {$acl_m_prf}{RTMail}}
           condition = ${if and{{!match {${lc:$rh_Subject:}} {debian rt}} \