From 71904e0d41c8cd254c347ac47d9c2591b671bc38 Mon Sep 17 00:00:00 2001 From: adam Date: Sat, 17 Mar 2007 09:02:02 +0000 Subject: [PATCH] auto-whitelist people we send email to darcs-hash:20070317090202-5007d-6e2c236e71c53be11d449d56e747efd9d37fcac3.gz --- src/org/ibex/mail/SMTP.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/org/ibex/mail/SMTP.java b/src/org/ibex/mail/SMTP.java index bf162fb..eed1a31 100644 --- a/src/org/ibex/mail/SMTP.java +++ b/src/org/ibex/mail/SMTP.java @@ -185,6 +185,11 @@ public class SMTP { } else if (conn.getRemoteAddress().isLoopbackAddress() || (from!=null&&from.toString().indexOf("johnw")!=-1)) { conn.println("250 you are connected locally, so I will let you send"); to.addElement(addr); + whitelist.addWhitelist(addr); + } else if (authenticatedAs!=null) { + conn.println("250 you are authenticated as "+authenticatedAs+", so I will let you send"); + to.addElement(addr); + whitelist.addWhitelist(addr); } else { conn.println("535 sorry, " + addr + " is not on this machine, you are not connected from localhost, and I will not relay without SMTP AUTH"); Log.warn("","535 sorry, " + addr + " is not on this machine, you are not connected from localhost, and I will not relay without SMTP AUTH"); -- 1.7.10.4