[Mailman-Users] How to discard spam without review

Carl Appellof cappello at legato.com
Mon Dec 18 19:14:40 CET 2000

Dan Mick says:
> Edit SpamDetect.py; here's what I've added; the syslog stuff is
> just for my personal edification; you could merely make the 
> analagous changes to KNOWN_SPAMMERS and have the effect you want.
> 28a29
> > from Mailman.Logging.Syslog import syslog
> 40c41
> ---
> > KNOWN_SPAMMERS = [('from', 'danyb at earthlink.net'), ('from', 
> 'dannyb at dannybproductions.com'), ('from', 
> 'events at dannybproductions.com')]
> 57a59
> >             syslog("bounce", "message discarded: %s: %s" % 
> (header, regex))

That gets me some of what I want.  Maybe your diffs didn't come through
correctly.  In SpamDetect.py, I think I need to replace the following lines:

            # we've detected spam
<            Hold.hold_for_approval(mlist, msg, SpamDetected)
            # no return

            # we've detected spam
>            syslog("bounce", "message discarded: %s: %s" % (header, regex))

            # no return

I basically ended up doing the same thing in a different place.


More information about the Mailman-Users mailing list