procmail
[Top] [All Lists]

Re: Conditions Limitation

2000-08-08 12:39:59
Are you trying to make a spam filter?  I suggest you try out rblcheck
in addition.  I've really cut down my spam since implementing it.

http://sourceforge.net/project/?group_id=2081

Here's my recipe:

FILTER_FOLDER=$HOME/mail/spam
RBLCHECK=$HOME/bin/rblcheck
QUAD="([1-9]|[1-9][0-9]|1[0-9][0-9]|2([0-4][0-9]|5[0-5]))"
IP="(${QUAD}\.${QUAD}\.${QUAD}\.${QUAD})"

# extract ip address
:0
* $ ^Received: from .*\[\/$IP
{
        TCPREMOTEIP=$MATCH
}

# check extracted ip address against black list
:0
* ! ? if [ -n "$TCPREMOTEIP" ]; then $RBLCHECK -q "$TCPREMOTEIP"; fi
{
        #EXITCODE=100
        LOGABSTRACT=all
        LOG="Filter: RBL-filtered address: \"$TCPREMOTEIP\""

        :0:
        $FILTER_FOLDER
}

On Tue, 8 Aug 2000, Eric Hilding wrote:


Is there a limitation to the number of conditions that can
be put in a particular recipe?  I've been trying all sorts
of things to axe <anything(_at_)xx(_dot_)com> that is unauthorized but
stuff keeps slipping through...like this bogus wall street
journal subscription by a forgerer:

Received: from zen2-exds (qmailr(_at_)zen2-exds(_dot_)strategy(_dot_)com 
[216.35.219.133])
       by winery.garlic.com (8.10.0/8.10.0) with SMTP id e78I8w517962
       for <xxx(_at_)xx(_dot_)com>; Tue, 8 Aug 2000 11:08:59 -0700
Received: (qmail 2340 invoked from network); 8 Aug 2000 17:46:33 -0000
Received: from unknown (HELO wasdc-ebse012.strategy.com) (10.60.49.96)
 by 10.60.80.106 with SMTP; 8 Aug 2000 17:46:33 -0000
Received: from mail pickup service by wasdc-ebse012.strategy.com with
Microsoft
   SMTPSVC;
        Tue, 8 Aug 2000 13:42:50 -0400

Here are the "Received:" lines from my modified (again) recipe:

* ^Received:.*\<for <[^ ]+(_at_)xx\(_dot_)com>
* ^Received:.*\<for <[^ ]+(_at_)XX\(_dot_)com>
* ^Received:.*\<for <(_dot_)*(_at_)xx\(_dot_)com>
* ^Received:.*\<for <(_dot_)*(_at_)XX\(_dot_)com>
* ^Received:(_dot_)*(_at_)xx\(_dot_)com
* ^Received:(_dot_)*(_at_)XX\(_dot_)com

Is there a limitation, or am I just all messed up here?

Tnx.

Eric



_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail



_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>