} 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");