spam filtering and spam score headers

140 views
Skip to first unread message

Jeff Folk

unread,
Jan 26, 2015, 8:41:28 PM1/26/15
to neths...@googlegroups.com
I've finally migrated my users over to my Neth Server install and started delivering email through the system. I have a question about when amavis-new adds the spam score headers. All my messages that have been labelled as ***SPAM*** have the headers added, but none of the other messages do.

Are the headers added to all mail? Or is my system not scanning all my messages? I do see the X-Virus-Scanned headers added to all mail.
It would be useful to see those scores to base my lower threshold adjustments. I currently have the lower set to 2.8, and the upper set to 6. I'm getting lots of missed spam and am trying to tweak things.

I did find how to add the Zen DNSBL list to the configuration (in the developer manual), so I have done that. What are other users using for anti-spam settings in the Neth environment?

Thanks for your suggestions!

Jeff

Filippo Carletti

unread,
Jan 27, 2015, 5:04:41 AM1/27/15
to Jeff Folk, neths...@googlegroups.com
AFAIK, amavis adds spam header only if score is above 2.0. I think
it's tunable, though.
The suggested spamassassin threshold is 5.0 per "maybe spam" and
should not be lowered too much.
I rely heavily on bayesian filters to catch spam. I usually pick a
"good user" and use his mail archive to train the filters.
Something like (being "filippo" the good user):

cd /var/lib/nethserver/vmail/filippo/Maildir/.Sent/cur
sa-learn -L --ham --dbpath /var/spool/amavisd/.spamassassin $(ls -t | head -300)
cd /var/lib/nethserver/vmail/filippo/Maildir/.junkmail/cur/
sa-learn -L --spam --dbpath /var/spool/amavisd/.spamassassin $(ls -t |
head -300)

Then I check that SpamAssassin has enough (200) mails to start using bayes:

su amavis -s /bin/sh -c 'sa-learn --dump magic'

nham and nspam should be above 200.

To train bayes, a user needs to move spam to the junkmail folder:
http://docs.nethserver.org/en/latest/mail.html#anti-spam

How did you enable the Zen DNSBL?
Could you send send me some unrecognized spam samples in eml/mailbox
format in a pass protected zip file?
> --
> You received this message because you are subscribed to the Google Groups
> "NethServer" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to nethserver+...@googlegroups.com.
> To post to this group, send email to neths...@googlegroups.com.
> To view this discussion on the web, visit
> https://groups.google.com/d/msgid/nethserver/01beb45f-8d84-4060-8a96-c5ed10a81f66%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



--
Ciao,
Filippo

Jeff Folk

unread,
Jan 27, 2015, 9:03:54 PM1/27/15
to neths...@googlegroups.com, macw...@gmail.com
On Tuesday, January 27, 2015 at 4:04:41 AM UTC-6, Filippo Carletti wrote:
AFAIK, amavis adds spam header only if score is above 2.0. I think
it's tunable, though.
The suggested spamassassin threshold is 5.0 per "maybe spam" and
should not be lowered too much.

Been watching my junk mail folder, and no ham, yet… I'll have to do a search to see what changes to the conf file I need to make.
 
I rely heavily on bayesian filters to catch spam. I usually pick a
"good user" and use his mail archive to train the filters.
Something like (being "filippo" the good user):

cd /var/lib/nethserver/vmail/filippo/Maildir/.Sent/cur
sa-learn -L --ham --dbpath /var/spool/amavisd/.spamassassin $(ls -t | head -300)
cd /var/lib/nethserver/vmail/filippo/Maildir/.junkmail/cur/
sa-learn -L --spam --dbpath /var/spool/amavisd/.spamassassin $(ls -t |
head -300)

Then I check that SpamAssassin has enough (200) mails to start using bayes:

su amavis -s /bin/sh -c 'sa-learn --dump magic'

nham and nspam should be above 200.

To train bayes, a user needs to move spam to the junkmail folder:
http://docs.nethserver.org/en/latest/mail.html#anti-spam

That's good to know, I've set all our Macs to send each mail to the junkmail folder when using the junk button in mail, so would accomplish the same result as our 'Learn as spam' folder using unjunkmgr in SME. 
 
How did you enable the Zen DNSBL?

db configuration setprop postfix RblStatus enabled RblServers zen.spamhaus.org
signal-event nethserver-mail-filter-save
 
Could you send send me some unrecognized spam samples in eml/mailbox
format in a pass protected zip file?

I'm going to give the mechanisms the chance to do their thing.  I realize there is a period of time where a new system has to 'grow up'.

Filippo Carletti

unread,
Jan 28, 2015, 6:09:27 AM1/28/15
to Jeff Folk, neths...@googlegroups.com
> Been watching my junk mail folder, and no ham, yet… I'll have to do a search
> to see what changes to the conf file I need to make.

False positives are rare.

>> To train bayes, a user needs to move spam to the junkmail folder:

> That's good to know, I've set all our Macs to send each mail to the junkmail
> folder when using the junk button in mail, so would accomplish the same
> result as our 'Learn as spam' folder using unjunkmgr in SME.

Yes, and using the button makes it intuitive and easy.

> db configuration setprop postfix RblStatus enabled RblServers
> zen.spamhaus.org
> signal-event nethserver-mail-filter-save

Thanks. I'll try that.

> I'm going to give the mechanisms the chance to do their thing. I realize
> there is a period of time where a new system has to 'grow up'.

Yes, my commands (sa-learn) are used to speed up "the grow".


--
Ciao,
Filippo

Jeff Folk

unread,
Jan 28, 2015, 8:17:55 AM1/28/15
to NethServer English
On Jan 28, 2015, at 5:09 AM, Filippo Carletti wrote:
>
>> That's good to know, I've set all our Macs to send each mail to the junkmail
>> folder when using the junk button in mail, so would accomplish the same
>> result as our 'Learn as spam' folder using unjunkmgr in SME.
>
> Yes, and using the button makes it intuitive and easy.

And automatic when the next one comes in! ;-)
Reply all
Reply to author
Forward
0 new messages