Move Spam Emails to Junk directory - tagged how, X-Spam-* headers missing

Discussion in 'Installation/Configuration' started by wjk940, Aug 25, 2016.

  1. wjk940

    wjk940 New Member

    1) In looking at the manual:
    Move Spam Emails to Junk directory: If you check this, emails that are tagged as spam by the spamfilter will automatically be moved to the junk folder. Please note that you can access the junk folder only if you use IMAP. This filter is active only if the spamfilter is active for this email account (i.e., a spamfilter level other than Uncensored must be selected, either for the whole mail domain or specifically for this email account).​
    is 'tagged' the value of "SPAM subject tag2" found the the subject header (presumes "SPAM modifies subject" is 'yes') or the value of X-Spam-Score is >= to the value of "SPAM tag2 level" for the policy associated with the mailbox?

    2) My root problem is far too many emails with only the X-Virus-Scanned header, and none of the X-Spam-* headers. My guess is most of the spam in my users' inbox would have a high enough X-Spam-Score to rewrite the subject and get moved to the Junk folder if the X-Spam-* headers were not missing. Does amavisd-new stop processing a message? How might a message get scanned for virus, but the SpamAssassin library not be invoked to score the message and write the X-Spam-* headers? [Yes, off topic for this forum, need to take this up on the SpamAssassin list.]

    BillK
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    The "X-Virus-Scanned header" indicates that the mail is scanned for spam and viruses, there is no additional scan header for spam. When the spam score exceeds the spam tag level that you have set in that policy, then these headers get added:

    X-Spam-Flag: No
    X-Spam-Score: 1.2
    X-Spam-Level:
    X-Spam-Status: Yes, score=1.2

    when the spam score exceeds the level that you have set as spam tag 2 level, then the message gets tagged like this:

    X-Spam-Flag: YES
    X-Spam-Score: 8.859
    X-Spam-Level: ********
    X-Spam-Status: Yes, score=8.859

    and the subject gets changed if you configured it in your policy.
     
  3. wjk940

    wjk940 New Member

    This is straightforward. There still seems to be a gap. If Spam Tag Level were zero, why would one see negative X-Spam-Score header? In my case, I have Spam Tag Level set to -9999, with the expectation of headers getting added to every message.

    The message not getting headers added are spam, so I'm puzzled as to why the headers are not added. Without the header, I cannot tell if the spam message is getting scored as ham.
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Then this policy git not applied to this email. Turn on debugging in amavis to see in detail in the mail.log which policy gets applied to an incoming email.
     

Share This Page