On Thursday 2 October 97, at 12 h 33, the keyboard of Timothy J Luoma
<luomat(_at_)peak(_dot_)org> wrote:
Does anyone have some relatively simple scoring examples?
These are real-life recipes:
# Trash the messages in german in the mailing list (they are a lot)
:0
* ^TO_isdn4linux
{
# Grep the body only
:0B
# Start with a negative value. All mail will be considered as
# "non german" at the beginning.
* -200^0
# Give a positive score for german letters or words
* 100^2 ß
* 10^2 .\<(bitte|mein|wie|der|das|ich|gute|mit|ist|alles|und|was|a
ch|ja|ueber|die|ich|unter|ein|alle)\>
# And a negative one for english words (some messages can be in
mixed languages
* -5^2 .\<(yes|please|the|of|your|other)\>
# man procmailsc for details
{ }
SCORE=$=
:0f
| formail -i "X-Filtered-German: semantic ($SCORE)"
:0
* $${SCORE}^0
tmp/Deutsch
}
# An anti-spam recipe (not really efficient). Scoring is mandatory
# because no "binary", "all or nothing" rule can work against spam.
:0
# Start with a negative value. All mail will be considered as
# "non spam" at the beginning.
* -250^0
# Words (or letters such as !) frequently found in spam have a high score
* 200^0 ^Subject:.*\!\!\!
* 100^1 ^Subject:.*\<free|sex|opportunity|money|great\>
* 100^0 ^From:.*\.com\>
* 100^0 ^Subject:.*\$
# And a negative one for replies (spams seem never to have Re:)
* -250^0 ^Subject: *Re:
* -250^0 ^Subject: *Fwd:
{ }
SCORE=$=
:0
* $${SCORE}^0
{
:0f
| formail -i "X-Filtered-Spam: semantic ($SCORE)"
:0
| /usr/lib/mh/rcvstore +L/Antispam/Spams/Auto
}
:0f
| formail -i "X-Not-Filtered-Spam: semantic ($SCORE)"