You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Roman Gelfand <rg...@gmail.com> on 2016/02/28 18:53:31 UTC

Score Assignment

Consider the following header

X-Spam-Status: No, score=4.4 required=5.0 tests=AWL,BAYES_99,BAYES_999,
	DCC_CHECK,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HTML_MESSAGE,
	RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.2


Where the scores configured for the above test?  Also, if there is a
command that would show the running scores for these tests.


Thanks in advance.

Re: Score Assignment

Posted by Reindl Harald <h....@thelounge.net>.

Am 28.02.2016 um 18:53 schrieb Roman Gelfand:
> Consider the following header
>
> X-Spam-Status: No, score=4.4 required=5.0 tests=AWL,BAYES_99,BAYES_999,
> 	DCC_CHECK,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HTML_MESSAGE,
> 	RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.2
>
>
> Where the scores configured for the above test?  Also, if there is a command that would show the running scores for these tests.


[root@mail-gw:~]$ sa-score.sh SPF_PASS
/usr/share/spamassassin
score SPF_PASS -0.001

/var/lib/spamassassin/3.004001/updates_spamassassin_org
score SPF_PASS -0.001

/etc/mail/spamassassin/local-*.cf
score SPF_PASS -0.05
_________________________________

[root@mail-gw:~]$ cat /usr/local/bin/sa-score.sh
#!/usr/bin/bash

su -c "/usr/bin/bash /usr/local/bin/workers/sa-score.sh $1" - sa-milt
[root@mail-gw:~]$ cat /usr/local/bin/workers/sa-score.sh
_________________________________

#!/usr/bin/bash

UPDATE_DIR="/var/lib/spamassassin/3.004001/updates_spamassassin_org"

echo "/usr/share/spamassassin"
cat /usr/share/spamassassin/*.cf | grep --text "score" | grep --text -v 
-P '^#' | grep --text --color "$1"
echo ""

echo "$UPDATE_DIR"
cat $UPDATE_DIR/*.cf | grep --text "score" | grep --text -v -P '^#' | 
grep --text --color "$1"
echo ""

echo "/etc/mail/spamassassin/local-*.cf"
cat /etc/mail/spamassassin/local*.cf | grep --text "score" | grep --text 
-v -P '^#' | grep --text --color "$1"


Re: Score Assignment

Posted by RW <rw...@googlemail.com>.
On Sun, 28 Feb 2016 12:53:31 -0500
Roman Gelfand wrote:

> Consider the following header
> 
> X-Spam-Status: No, score=4.4 required=5.0
> tests=AWL,BAYES_99,BAYES_999,
> DCC_CHECK,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HTML_MESSAGE,
> RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.2
> 
> 
> Where the scores configured for the above test?  Also, if there is a
> command that would show the running scores for these tests.

Note that the configured scores may have been changed by the time you
look them  up.

You might find it useful to add this to your config:


add_header all Report _REPORT_


Alternately if you don't want to add another header, you can redefine
X-Spam-Status to show the scores with:


add_header all Status _YESNO_, score=_SCORE_ required=_REQD_ tests=_TESTSCORES_ autolearn=_AUTOLEARN_ version=_VERSION_