Page 1 of 4

SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 1:03 am
by SS88
Hello VestaCP Community!

I have now merged this topic to GitHub. I am reluctant to keep it updated on VestaCP forums - but it will forever stay updated on GitHub.

https://github.com/SS88UK/SpamAssassinRules

Once you have installed the rules and restarted SpamAssassin the rules will help reduce spam on your server.

Re: SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 1:41 am
by pandabb
Thanks will try this in future.

Re: SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 10:18 am
by Sanity
testing...
thank you!

Re: SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 10:40 am
by SS88
I have added these to it too:

Code: Select all

score   URIBL_DBL_SPAM          5.0
score   RCVD_IN_PSBL            5.0

Re: SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 3:09 pm
by Sanity
in the spamassassin you have to change something to read the file?

Re: SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 3:15 pm
by SS88
Sanity wrote:in the spamassassin you have to change something to read the file?
Nope SA reads ".cf" files.

Re: SpamAssassin Rules We All NEED

Posted: Tue Apr 26, 2016 5:00 pm
by Sanity
I imagined but to confirm it. thank you very much! :)

Re: SpamAssassin Rules We All NEED

Posted: Fri Apr 29, 2016 7:11 am
by Sanity
Hello, I'm getting a lot of spam. but thank you very much!

Re: SpamAssassin Rules We All NEED

Posted: Fri Apr 29, 2016 11:32 am
by SS88
Sanity wrote:Hello, I'm getting a lot of spam. but thank you very much!
Has it reduced or not?

You could view the headers of the email to see the SpamAssassin tests performed.

Re: SpamAssassin Rules We All NEED

Posted: Wed May 11, 2016 12:51 pm
by SS88
As of today, the first post has been updated as it was showing errors in my logs.

All SA rules must all be on one line, otherwise those rules are ignored.

This has been changed/added (if statements added):

Code: Select all

ifplugin Mail::SpamAssassin::Plugin::Shortcircuit

meta SC_HAM (USER_IN_WHITELIST||USER_IN_DEF_WHITELIST||USER_IN_ALL_SPAM_TO||NO_RELAYS||ALL_TRUSTED)
priority SC_HAM -1000
shortcircuit SC_HAM ham
score SC_HAM -20

endif
and this has been modified so more weight 3.0 to 5.0 is added if the sender is on multiple blacklists

Code: Select all

meta       CUSTOM_RCVD_IN_MANY (( RCVD_IN_BL_SPAMCOP_NET + RCVD_IN_SBL + RCVD_IN_XBL + RCVD_IN_SORBS_DUL + RCVD_IN_SORBS_SMTP + RCVD_IN_NJABL_RELAY + RCVD_IN_DSBL + RCVD_IN_NJABL_SPAM + RCVD_IN_NJABL_PROXY + RCVD_IN_SORBS_HTTP + RCVD_IN_SORBS_BLOCK + RCVD_IN_PSBL + URIBL_DBL_SPAM) > 2)
describe   CUSTOM_RCVD_IN_MANY   Message received in more than 2 RBLs
score      CUSTOM_RCVD_IN_MANY 5.0
Other fixes have been made, please update the rules in the first post.