Disable spam processing for account
MailScanner at ecs.soton.ac.uk
Sun Sep 4 11:14:30 IST 2011
Just found one feature I remembered writing but can't find in the docs.
If you make a ruleset file that looks like this 1 line:
FromOrTo: /etc/my_addresses.txt no
Then you put 1 "pattern" (i.e. what would go in the 2nd field in a
ruleset line) per line in /etc/my_addresses.txt. Then it just duplicates
the "FromOrTo: ..... no" rule for every line read from
The result is this. If you have a lot of entries with the same rule
result (such as in a spam whitelist for example), you don't have to
generate a ruleset file which looks like
FromOrTo: customer at client.com yes
FromOrTo: customer2 at client.com yes
FromOrTo: customer3 at client2.com yes
All you actually need to do is create the ruleset file to look like this
FromOrTo: /etc/MailScanner/MyCustomers.txt yes
and then generate a file /etc/MailScanner/MyCustomers.txt which contains
a list of all your customers' email addresses, like this
customer at client.com
customer2 at client.com
customer3 at client2.com
The advantage is that the code to generate the file is a lot simpler,
and you don't have to worry so much about syntax. And maybe you can just
copy the file from somewhere else in your system and not have to
specifically generate it *at all*.
Just thought you might like to know that one. Why I never documented it,
I really don't know. Sorry!
P.S. In the above message, all the indents at the start of the lines are
purely there so you can see what is sample file contents and what are my
ramblings. You shouldn't actually put the indents at the start of the
lines in the config files!
On 03/09/2011 21:23, Kristofer Pettijohn wrote:
> Ahh, I missed that it can be a rule set. Thank you.
> *From: *"Martin Hepworth" <maxsec at gmail.com>
> *To: *"MailScanner discussion" <mailscanner at lists.mailscanner.info>
> *Sent: *Saturday, September 3, 2011 2:52:00 PM
> *Subject: *Re: Disable spam processing for account
> The mailscanner.conf setting u want to hang the ruleset of is "spam
> checks". Look in the rules dir and you'll see plenty of examples of
> how to set this up.
> Also check the wiki for more examples
> On Saturday, 3 September 2011, Kristofer Pettijohn
> <kristofer at cybernetik.net <mailto:kristofer at cybernetik.net>> wrote:
> > Hello,
> > Is it possible to disable spam scanning for an account, or a list of
> accounts? I have a few backup accounts where I want it to skip spam
> scanning and simply just deliver everything.
> > I was thinking that "SpamAssassin Rule Actions" would be an ideal
> place for this, but I don't quite understand the ruleset enough to
> know how to accomplish this.
> > I am currently having MailScanner set a header in the email and
> deliver, and then my mail server filters it into a "Junk" folder. I
> would like it to not add this header for a certain list of accounts.
> > Spam Actions = deliver header "X-Organization-Spam-Status: Yes"
> > Thanks in advance
> > --
> > MailScanner mailing list
> > mailscanner at lists.mailscanner.info
> <mailto:mailscanner at lists.mailscanner.info>
> > http://lists.mailscanner.info/mailman/listinfo/mailscanner
> > Before posting, read http://wiki.mailscanner.info/posting
> > Support MailScanner development - buy the book off the website!
> Martin Hepworth
> Oxford, UK
> MailScanner mailing list
> mailscanner at lists.mailscanner.info
> Before posting, read http://wiki.mailscanner.info/posting
> Support MailScanner development - buy the book off the website!
> Julian Field MEng CITP CEng
> Buy the MailScanner book at www.MailScanner.info/store
> Need help customising MailScanner? Contact me!
> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
> Follow me at twitter.com/JulesFM
> 'Teach a man to reason, and he will think for a lifetime.' - Phil Plait 'All programs have a desire to be useful' - Tron, 1982
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
More information about the MailScanner