Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto Delete Double Bounce Spam

Status
Not open for further replies.

jdeaner

MIS
Jan 7, 2003
61
0
0
US
I have a qmail server relaying mail to another server that is using LDAP. The qmail server is acting as a backup MX server. What can be done about messages received by qmail but rejected upon relay to the main server due to an invalid mailbox? Obviously the spam messages have invalid return addresses which leave them in the qmail queue and waste resources via DNS lookups. Ideally they would be rejected and never queued but the qmail server is set up to accept all mail for the domain (except RBL IP's) when the main server is off-line. Any ideas other than qmail-ldap, reverse DNS lookups, or user whitelists?
 
Anyone use this doublebounce-trim patch on qmail-1.05 or have a modified version of it:

diff -urN qmail-1.03.orig/qmail-send.9 qmail-1.03.nodoublebounce/qmail-send.9
--- qmail-1.03.orig/qmail-send.9 Mon Jun 15 04:53:16 1998
+++ qmail-1.03.nodoublebounce/qmail-send.9 Tue Sep 9 12:59:04 2003
@@ -115,6 +115,10 @@
(If that bounces,
.B qmail-send
gives up.)
+As a special case, if the first line of
+.IR doublebounceto
+is blank (contains a single linefeed), qmail-send will not queue
+the double-bounce at all.
.TP 5
.I envnoathost
Presumed domain name for addresses without @ signs.
diff -urN qmail-1.03.orig/qmail-send.c qmail-1.03.nodoublebounce/qmail-send.c
--- qmail-1.03.orig/qmail-send.c Mon Jun 15 04:53:16 1998
+++ qmail-1.03.nodoublebounce/qmail-send.c Tue Sep 9 13:02:43 2003
@@ -683,6 +683,8 @@
}
if (str_equal(sender.s,"#@[]"))
log3("triple bounce: discarding ",fn2.s,"\n");
+ else if (!*sender.s && *doublebounceto.s == '@')
+ log3("double bounce: discarding ",fn2.s,"\n");
else
{
if (qmail_open(&qqt) == -1)

--9jxsPFA5p3P2qPhR--
 
You should take a look at this diagram from a very respected qmail hacker. His model for handling spam depends upon putting into service the "chkuser" patch and having the front-end mail gateways able to use it via a shared database.



D.E.R. Management - IT Project Management Consulting
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top