Subject score differs from actual score

2019-09-06 Thread David Galloway
Hi,

I'm running SpamAssassin 3.4.2 on Ubuntu 16.04 with Postfix and Mailman3.

Occasionally, SpamAssassin will rewrite a message's subject with a score
higher than what's in X-Spam-Status.  This is not a rounding issue.

For example, I'm looking at an e-mail now with "* SPAM 5.4 *" in
the subject but "X-Spam-Status: No, score=3.2 required=5.0"

There is no instance of SpamAssassin between the mail server and me that
could have added the score to the subject.

Here is another one:
https://lists.ceph.io/hyperkitty/list/d...@ceph.io/thread/TI3K42RGVJ3ZB6O4NUPNCUWHGVHNDY53/

8.4 in the subject but "X-Spam-Status: No, score=4.9"

Here is my /etc/spamassassin/local.cf (~/.spamassassin config is not used):
rewrite_header Subject * SPAM _SCORE_ *
report_safe 0
required_score  5.0
use_bayes   1
use_bayes_rules 1
bayes_auto_learn1
skip_rbl_checks 0
use_razor2  0
use_dcc 0
use_pyzor   0

-- 
David Galloway
Systems Administrator, RDU
Ceph Engineering
IRC: dgalloway


Re: Score in subject differs from score in headers

2019-09-06 Thread David Galloway


On 9/6/19 4:16 PM, Matus UHLAR - fantomas wrote:
>>>> On 9/6/2019 11:45 AM, David Galloway wrote:
>>>>> I'm running SpamAssassin 3.4.2 on Ubuntu 16.04 with Postfix and
>>>>> Mailman3.
>>>>>
>>>>> Occasionally, SpamAssassin will rewrite a message's subject with a
>>>>> score
>>>>> higher than what's in X-Spam-Status.  This is not a rounding issue.
>>>>>
>>>>> For example, I'm looking at an e-mail now with "* SPAM 5.4
>>>>> *" in
>>>>> the subject but "X-Spam-Status: No, score=3.2 required=5.0"
>>>>>
>>>>> AFAIK, there is no instance of SpamAssassin between the mail server
>>>>> and
>>>>> me that
>>>>> could have added the score to the subject.
> 
> On 06.09.19 16:11, David Galloway wrote:
>> I'm not crazy!
> 
>> https://lists.ceph.io/hyperkitty/list/d...@ceph.io/thread/GN3DLKWDIW2NUDO4T4MZG6E5FQEIB7NN/
>>
>>
>> 7.3 in the subject (that my SpamAssassin instance definitely set) and:
>> X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on lists.ceph.io
>> X-Spam-Level: *
>> X-Spam-Status: No, score=1.8 required=5.0
>> tests=FREEMAIL_REPLYTO_END_DIGIT,
>> MAILING_LIST_MULTI,RCVD_IN_RP_RNBL,RDNS_NONE,SPF_HELO_NONE,
>> SUBJ_OBFU_PUNCT_FEW,URIBL_BLOCKED autolearn=no autolearn_force=no
>> version=3.4.2
> 
> are you sure you don't process mail two times, when delivering to list and
> when delivering to end-users (you)?
> 

Oof, that is exactly what was happening.  Which leads me to figuring out
why my mailman header filter regex isn't working.

Anyway, thanks for the help!


Re: Score in subject differs from score in headers

2019-09-06 Thread David Galloway


On 9/6/19 12:06 PM, David Galloway wrote:
> 
> On 9/6/19 12:01 PM, Bowie Bailey wrote:
>> On 9/6/2019 11:45 AM, David Galloway wrote:
>>> Hi,
>>>
>>> I'm running SpamAssassin 3.4.2 on Ubuntu 16.04 with Postfix and Mailman3.
>>>
>>> Occasionally, SpamAssassin will rewrite a message's subject with a score
>>> higher than what's in X-Spam-Status.  This is not a rounding issue.
>>>
>>> For example, I'm looking at an e-mail now with "* SPAM 5.4 *" in
>>> the subject but "X-Spam-Status: No, score=3.2 required=5.0"
>>>
>>> AFAIK, there is no instance of SpamAssassin between the mail server and
>>> me that
>>> could have added the score to the subject.
>>
>> The instance of SpamAssassin that changed the subject would have been before 
>> it got
>> to your server.  Since your server does not mark the email as spam, it 
>> doesn't change
>> the subject, and so the previous markup is left there.  If your server had 
>> marked the
>> email as spam, then it would have either changed the number to be correct, 
>> or added a
>> second spam tag to the subject (depending on how smart SA's subject 
>> rewriting routine
>> is).
>>
> 
> I didn't start seeing the subjects being changed until after I enabled
> SpamAssassin on my mail server though.  I don't /think/ I'm crazy but as
> a litmus test, I just added my server's hostname to the rewrite_header
> Subject parameter and will wait for spam to come in.
> 

I'm not crazy!

https://lists.ceph.io/hyperkitty/list/d...@ceph.io/thread/GN3DLKWDIW2NUDO4T4MZG6E5FQEIB7NN/

7.3 in the subject (that my SpamAssassin instance definitely set) and:
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on lists.ceph.io
X-Spam-Level: *
X-Spam-Status: No, score=1.8 required=5.0 tests=FREEMAIL_REPLYTO_END_DIGIT,
MAILING_LIST_MULTI,RCVD_IN_RP_RNBL,RDNS_NONE,SPF_HELO_NONE,
SUBJ_OBFU_PUNCT_FEW,URIBL_BLOCKED autolearn=no autolearn_force=no
version=3.4.2


Re: Score in subject differs from score in headers

2019-09-06 Thread David Galloway


On 9/6/19 12:01 PM, Bowie Bailey wrote:
> On 9/6/2019 11:45 AM, David Galloway wrote:
>> Hi,
>>
>> I'm running SpamAssassin 3.4.2 on Ubuntu 16.04 with Postfix and Mailman3.
>>
>> Occasionally, SpamAssassin will rewrite a message's subject with a score
>> higher than what's in X-Spam-Status.  This is not a rounding issue.
>>
>> For example, I'm looking at an e-mail now with "* SPAM 5.4 *" in
>> the subject but "X-Spam-Status: No, score=3.2 required=5.0"
>>
>> AFAIK, there is no instance of SpamAssassin between the mail server and
>> me that
>> could have added the score to the subject.
> 
> The instance of SpamAssassin that changed the subject would have been before 
> it got
> to your server.  Since your server does not mark the email as spam, it 
> doesn't change
> the subject, and so the previous markup is left there.  If your server had 
> marked the
> email as spam, then it would have either changed the number to be correct, or 
> added a
> second spam tag to the subject (depending on how smart SA's subject rewriting 
> routine
> is).
> 

I didn't start seeing the subjects being changed until after I enabled
SpamAssassin on my mail server though.  I don't /think/ I'm crazy but as
a litmus test, I just added my server's hostname to the rewrite_header
Subject parameter and will wait for spam to come in.


Score in subject differs from score in headers

2019-09-06 Thread David Galloway
Hi,

I'm running SpamAssassin 3.4.2 on Ubuntu 16.04 with Postfix and Mailman3.

Occasionally, SpamAssassin will rewrite a message's subject with a score
higher than what's in X-Spam-Status.  This is not a rounding issue.

For example, I'm looking at an e-mail now with "* SPAM 5.4 *" in
the subject but "X-Spam-Status: No, score=3.2 required=5.0"

AFAIK, there is no instance of SpamAssassin between the mail server and
me that
could have added the score to the subject.

Here is another one:
https://lists.ceph.io/hyperkitty/list/d...@ceph.io/thread/TI3K42RGVJ3ZB6O4NUPNCUWHGVHNDY53/

8.4 in the subject but "X-Spam-Status: No, score=4.9"

Here is my /etc/spamassassin/local.cf (~/.spamassassin config is not used):
rewrite_header Subject * SPAM _SCORE_ *
report_safe 0
required_score  5.0
use_bayes   1
use_bayes_rules 1
bayes_auto_learn1
skip_rbl_checks 0
use_razor2  0
use_dcc 0
use_pyzor   0

-- 
David Galloway
Systems Administrator, RDU
Ceph Engineering
IRC: dgalloway