Whitelist.java: never send a challenge in response to a List-Id or List-Post
[org.ibex.mail.git] / src / org / ibex / mail / Whitelist.java
index 7355a5c..9842320 100644 (file)
@@ -141,6 +141,10 @@ public class Whitelist extends SqliteDB {
                          "with Auto-Submitted=\""+m.headers.get("Auto-Submitted")+"\"");
                 return;
             }
+            if (m.headers.get("List-Id") != null || m.headers.get("List-Post") != null) {
+                Log.warn(this, "refusing to send a challenge to a message with a List-Id or List-Post header");
+                return;
+            }
 
             Address from = Address.parse("adam@megacz.com");