[TriLUG] Are you troubled by... ;-)

Tanner Lovelace lovelace at wayfarer.org
Fri Aug 29 01:16:43 EDT 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Is your mailman list bogged down with SoBig?  Are you having
trouble wading through the moderation queue?  Are you using
mailman 2.1?  Well, if so, then help is here.  With these
simple procmail rules you can have mailman automatically
discard potential SoBig messages that have been held for
moderation.  All you have to do is add this to your .procmailrc
file in your home directory, change the values to match your
list and voila!  Never worry about SoBig in your moderation
queue again.  Act now, and we'll even through in a GPL license
for these rules at "no extra charge!"  This offer is not available
in stores!  Tell people you heard it here on the TriLUG mailing list.

- ----------------------------- snip ---------------------------------
#################################################################
## If we get a message from mailman and it's about a virus,
## extract the confirm string from it and send it back so
## we automatically discard that message.
#################################################################

:0 W
* ^Subject.*MAILINGLISTNAME post from
{
~   HELDSUBJ=`formail +1 -ds|formail -x "Subject:" \
~     |sed -e 's/[;\`\\]/ /g'|expand \
~     |sed -e 's/^[ ]*//g' -e 's/[ ]*$//g'`
~   CONFIRM=`formail +2 -ds|formail -x "Subject:" \
~     |sed -e 's/[;\`\\]/ /g'|expand \
~     |sed -e 's/^[ ]*//g' -e 's/[ ]*$//g'`
~   # Apparently, this can sometimes extract the e-mail address
~   # of the list itself!!! So, instead, let's hardcode the
~   # request address.
~   #DELADDR=`formail +2 -ds  | formail -x "From:"`
~   DELADDR="MAILINGLISTNAME-request at DOMAINNAME"

~   # check for the SoBig virus or an indication that this is a
~   # virus (we get bounces from some virus scanning software)
~   # Note the HELDSUBJ line is all on one line...
~   # Also note that we're piping the message but we're piping it
~   # to echo.  If we send the entire message to the confirm address
~   # the discard fails so we just send the confirm string itself.
~   # there's probably a much better way to do that...
~   :0 wc
~   * HELDSUBJ ?? (\{Virus\?\}|Re: Details|Re: Wicked screensaver|Re:
Approved|Re: Thank you\!|Re: That movie|Re: Your application| Your
details|Thank you\!|Re: My details)
~   | (echo "$CONFIRM" | /bin/mail -s "$CONFIRM" $DELADDR)

~    # If you don't want to save a copy of these messages,
~    # remove this line and the "c" from the above recipe
~    # note, however, that messages that don't match the
~    # above regex will probably go into your inbox or
~    # just be silently discarded.
~    :0
~    mailman-admin-messages
}
- ----------------------------- snip ---------------------------------

Cheers,
Tanner
(who seems to have watch one too many infomercial up this late ;-)
- --
Tanner Lovelace | lovelace at wayfarer.org | http://wtl.wayfarer.org/
- --*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--
GPG Fingerprint = A66C 8660 924F 5F8C 71DA  BDD0 CE09 4F8E DE76 39D4
GPG Key can be found at http://wtl.wayfarer.org/lovelace.gpg.asc
- --*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--
~ This would be a very good time to hang out with the Open Source
~ people, before they get formally reclassified as a national security
~ threat. -- Bruce Sterling



-----BEGIN PGP SIGNATURE-----
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQE/TuG6zglPjt52OdQRAglcAKCsJwJAeaLiPREYiNKwCD1WDEQFoACfUcPG
Cwqi6jZZLkdRo0eTowk06gs=
=ANv1
-----END PGP SIGNATURE-----




More information about the TriLUG mailing list