1

I am using spamassassin via Amavisd-new. I have amavisd set to include headers on spam and ham messages via "$sa_tag_level_deflt = -9999.0;"

2 questions...

a) I want to be sure I am configured to show as much detail as possibl efrom spamassassin in my headers. I have these 3 lines in my local.cf:

add_header all Status "_YESNO_, score=_SCORE_ required=_REQD_ tests=_TESTS_ _RBL_ autolearn=_AUTOLEARN_ version=_VERSION_ "

add_header all Pyzor _PYZOR_

add_header all  DCC _DCCB_: _DCCR_

How do I tell if I have everything? Is this it? For example I have Razor2 enabled, but I don't know if it has an explicit header setting. I want to be sure I'm including everything. Not sure if I'm omitting anything or not.

b) Is there a way to get it to show all tests in the headers, even those with zero scores?

shorton
  • 149
  • 1
  • 9

2 Answers2

0

Note, when using amavisd-new, it will drop non-default headers generated by SpamAssassin. To override that, you need to specify which headers amavisd should keep (eg. in /etc/amavis/conf.d/50-user) like this:

$allowed_added_header_fields{lc('X-Spam-Pyzor')} = 1;
$allowed_added_header_fields{lc('X-Spam-DCC')} = 1;
Matija Nalis
  • 2,478
  • 24
  • 37
  • thank you. Is there a way to figure out what all the SA non-default headers are? So they can be excluded or not? If it deletes them before I see them, not sure how to see what would have been there. – shorton Nov 03 '21 at 14:47
  • 1
    On the server, as the user running spamassassin (usually `amavis`) run the following: `spamassassin -t example_mail.txt | grep '^X-Spam'` (where `example_mail.txt` is any file containing rfc822 e-mail ). That should show all headers (default or extra ones added by `add_header`) that spamassassin is producing. – Matija Nalis Nov 04 '21 at 19:24
0

I think I found the list here:

http://spamassassin.apache.org/full/3.4.x/doc/Mail_SpamAssassin_Conf.html#template_tags

shorton
  • 149
  • 1
  • 9