Custom Rules

Jeff Graves jeff at IMAGE-SRC.COM
Mon Sep 26 20:45:04 IST 2005


I'm getting a bunch of spamis spam slipping through and I'm running older
versions of MailScanner and spamassasin (about a year old). I don't have
time right now to update or patch MailScanner or spamassin or add new
rules_du_jour or whatever. All I'd like to do for the time being, is add a
quick custom rule to catch this phrase "[ S P A M I S  NOTIFICATION ]:" but
I have no Perl regex experience. Spamassasin --lint complains about this
syntax to local.cf:

body SPAMIS_CUSTOM_RULE \b\[ S P A M I S NOTIFICATION\]
describe SPAMIS_CUSTOM_RULE Detects spam sent by spamis
score SPAMIS_CUSTOM_RULE 12.0

-----

spamassassin --lint
Backslash found where operator expected at /etc/mail/spamassassin/local.cf,
rule SPAMIS_CUSTOM_RULE, line 1, near "b\"
Backslash found where operator expected at /etc/mail/spamassassin/local.cf,
rule SPAMIS_CUSTOM_RULE, line 1, near "NOTIFICATION\"
Failed to compile body SpamAssassin tests, skipping:
        (syntax error at /etc/mail/spamassassin/local.cf, rule
SPAMIS_CUSTOM_RULE, line 1, near "b\"

I thought [] were reserved and need to be escaped with \... Help!

Jeff Graves, MCSA
Image Source, Inc.
10 Mill Street
Bellingham, MA 02019

508.966.5200 x31 - Phone
508.966.5170 - Fax
jeff at image-src.com - Email
www.image-src.com 

------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
'leave mailscanner' in the body of the email.
Before posting, read the Wiki (http://wiki.mailscanner.info/) and
the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).

Support MailScanner development - buy the book off the website!



More information about the MailScanner mailing list