You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spamassassin.apache.org by bu...@spamassassin.apache.org on 2023/05/02 08:43:22 UTC

[Bug 7943] TxRep gives nonsensical scores?

https://bz.apache.org/SpamAssassin/show_bug.cgi?id=7943

Giovanni Bechis <gi...@paclan.it> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |giovanni@paclan.it

--- Comment #4 from Giovanni Bechis <gi...@paclan.it> ---
Created attachment 5883
  --> https://bz.apache.org/SpamAssassin/attachment.cgi?id=5883&action=edit
Possible fix

Delta formula is:
$delta = ($self->total() + $msgscore) / (1 + $self->count()) - $msgscore;

If we consider the case when:
- TxRep database has 15 emails that matches ($self->count() = 15)
- spam message has score 40 (spam)
- calculated TxRep score is 20 (spam)
- new TxRep score will be (20 + 40) / ( 1 + 15 ) - 40 = -36.25
In this case the spam message will have a total score of 40 - 36.25 = 3.75 and
it won't be flagged as spam.

The attached patch doesn't consider those messages in the delta calculation.

-- 
You are receiving this mail because:
You are the assignee for the bug.