Non nesting rules

Howard Robinson Howard at HARPER-ADAMS.AC.UK
Thu Feb 3 16:39:55 GMT 2005

Thanks to Julian and several others who replied to this subject
earlier in the week.
(It may be teaching Grandmothers to suck eggs - that is still legal
in the UK- but for newbies and more timid users, like me, it may be

The problem was allowing 4 staff to accept email from 60 off
campus addresses without being spam checked. I could have
added a line for each combination but that would have been hard to
maintain - 4*60 = 240 lines at the moment!
The solution below means only two lists need amending should
more staff or students need adding or the in-decipherable email
address on the hand written list given to me need correcting .
A stop and restart of mailscanner was necessary.

In MaiLScanner.conf
Is Definitely Not Spam = %rules-dir%/spam.whitelist.rules

In %rules-dir%/spam.whitelist.rules
# This is where you can build a Spam WhiteList
# Addresses matching in here, with the value
# "yes" will never be marked as spam.
# Next line is wrapped over two lines in the email but one
# in the real file
To:     /etc/MailScanner/lists/harperstaff and  From:
/etc/MailScanner/lists/offcampuslist yes
FromOrTo:       default         no

In /etc/MailScanner/lists/harperstaff
I have 1 address per line
harperusera at mydomain
harperuserb at mydomain
harperuserc at mydomain
harperuserd at mydomain

in /etc/MailScanner/lists/offcampuslist
I have 1 addess per line
OffcampususerA at domain1
OffcampususerB at domain1
OffcampususerC at domain2
OffcampususerD at domain123

I have tried this using a Yahoo account and my harper account as
a test and it works fine. Mailwatch shows whitelisted emails in a
lovely shade of green.(-;

Thanks to Julian et al for a great package
By the way got the book and I am finding it useful.


Howard Robinson
(Senior Technical Development Officer)
Harper Adams University College

E-mail: hrobinson at
Tel.  : +44(0)1952 820280 Via switchboard
      : +44(0)1952 815253 Direct line
Fax.  : +44(0)1952 814783
College Web site

------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at with the words:
'leave mailscanner' in the body of the email.
Before posting, read the MAQ ( and
the archives (

Support MailScanner development - buy the book off the website!

More information about the MailScanner mailing list