Once SpamAssassin has been trained with enough spam and ham emails, it will begin to apply the Bayesian test automatically, if it is enabled. However, not every email will receive a Bayesian score. The Bayesian subsystem only gives a probability if it can make an authoritative estimate. To do this, it needs to recognize words (more correctly tokens) that it has seen in previous ham or spam emails. One way to confirm the operation of the Bayesian filter is to examine the headers of emails that have been processed by SpamAssassin and search for the result of a BAYES_
test. The X-Spam-Status
header in an email may look like this:
X-Spam-Status: No, hits=3.5 required=4.0 tests=BAYES_50,DATE_IN_PAST_03_06, RCVD_IN_RFCI,RCVD_IN_SBL autolearn=no version=3.00
The X-Spam-Status:
header lists all the tests that the email triggered along with some other details. In this example, the BAYES_50
test was fired, indicating around 50% probability that the email was spam. If any BAYES_...