You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Halid Faith <ma...@ihlas.net.tr> on 2006/08/11 10:49:16 UTC

Sa-learn doesn't seem to work

Hello

I use spamassassin3.1 with simscan1.2 on qmail.
I want my mailserver to deny some messages which are spam using sa-learn. So I typed as below;
sa-learn --spam /path/badmails/

Learned tokens from 6 message(s) (6 message(s) examined)

Despite I learnt to my server as spam with the above way (sa-learn),  when I sent a spam message to the server, I got that email which I put in /path/badmails/.
Here is  a part of the header in that email;
Return-Path: user@domain
Delivered-To: someone@domain
X-Spam-DCC: sonic.net: snort.domain.net 1156; Body=1 Fuz1=1 Fuz2=1
X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on snort.domain.net
X-Spam-Level: ***
X-Spam-Status: No, score=3.7 required=10.0 tests=AWL,EXTRA_MPART_TYPE,
 HTML_MESSAGE,INFO_TLD,RAZOR2_CF_RANGE_51_100,
 RAZOR2_CF_RANGE_E8_51_100,RAZOR2_CHECK autolearn=no version=3.1.1
X-Spam-Pyzor: Reported 0 times.

The server gave a score but it didn't reject that message.
I think  my sa-learn doesn't seem to work.

my local.cf 
 rewrite_header Subject SPAMMSG
 required_score 9.0
add_header all DCC _DCCB_: _DCCR_
use_razor2 1
pyzor_path /usr/local/bin/pyzor
pyzor_max 2
use_pyzor 1
add_header all Pyzor _PYZOR_
use bayes 1
 bayes_auto_learn 1
use_dcc 1
dcc_path /usr/local/bin/dccproc
use_auto_whitelist 0 

init.pre  is below
loadplugin Mail::SpamAssassin::Plugin::DCC
loadplugin Mail::SpamAssassin::Plugin::Pyzor
loadplugin Mail::SpamAssassin::Plugin::Razor2
loadplugin Mail::SpamAssassin::Plugin::Hashcash

How can I reject a mail with sa-learn ?
Thanks

Re: Sa-learn doesn't seem to work

Posted by Nigel Frankcom <ni...@blue-canoe.net>.
On Fri, 11 Aug 2006 11:49:16 +0300, "Halid Faith"
<ma...@ihlas.net.tr> wrote:

>Hello
>
>I use spamassassin3.1 with simscan1.2 on qmail.
>I want my mailserver to deny some messages which are spam using sa-learn. So I typed as below;
>sa-learn --spam /path/badmails/
>
>Learned tokens from 6 message(s) (6 message(s) examined)
>
>Despite I learnt to my server as spam with the above way (sa-learn),  when I sent a spam message to the server, I got that email which I put in /path/badmails/.
>Here is  a part of the header in that email;
>Return-Path: user@domain
>Delivered-To: someone@domain
>X-Spam-DCC: sonic.net: snort.domain.net 1156; Body=1 Fuz1=1 Fuz2=1
>X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on snort.domain.net
>X-Spam-Level: ***
>X-Spam-Status: No, score=3.7 required=10.0 tests=AWL,EXTRA_MPART_TYPE,
> HTML_MESSAGE,INFO_TLD,RAZOR2_CF_RANGE_51_100,
> RAZOR2_CF_RANGE_E8_51_100,RAZOR2_CHECK autolearn=no version=3.1.1
>X-Spam-Pyzor: Reported 0 times.
>
>The server gave a score but it didn't reject that message.
>I think  my sa-learn doesn't seem to work.
>
>my local.cf 
> rewrite_header Subject SPAMMSG
> required_score 9.0
>add_header all DCC _DCCB_: _DCCR_
>use_razor2 1
>pyzor_path /usr/local/bin/pyzor
>pyzor_max 2
>use_pyzor 1
>add_header all Pyzor _PYZOR_
>use bayes 1
> bayes_auto_learn 1
>use_dcc 1
>dcc_path /usr/local/bin/dccproc
>use_auto_whitelist 0 
>
>init.pre  is below
>loadplugin Mail::SpamAssassin::Plugin::DCC
>loadplugin Mail::SpamAssassin::Plugin::Pyzor
>loadplugin Mail::SpamAssassin::Plugin::Razor2
>loadplugin Mail::SpamAssassin::Plugin::Hashcash
>
>How can I reject a mail with sa-learn ?
>Thanks


Unless you are logged into the SA box as the connector you will need
to do...

sa-learn --spam -u <SA SQL USERNAME> /path/to/spam

HTH

Nigel