Mail headers & classifying

David Relson relson at osagesoftware.com
Mon May 23 13:07:51 CEST 2005


On Mon, 23 May 2005 12:52:33 +0200
Peter BARABAS wrote:

> Hello,
> 
> Which mail headers does Bogofilter use when classifying a message? Can
> I configure that? I couldn't find it in the manual.
> 
> Thanks.
> 
> -- 
> '(Yours parenthetically),
> peter barabas.

Hello Peter,

Bogofilter parses all mail headers and uses all the tokens, with some
special processing and one exception.  

1) Tokens from To:, From:, Return-Path:, Subject:, Received:, Header:,
and Mime: mail headers are given special prefixes indicating the header
line type.

2) X-Bogosity: lines are deleted.

3) All other header lines are given a prefix of "head:".

You can see the tokens parsed using either bogofilter or bogolexer.
Running "bogolexer -p < message" will show you all the tokens for the
message (in the order encountered and, possibly, with duplications),
while "bogofilter -vvv < message" will give you a list of unique tokens
sorted by spam score.

HTH,

David




More information about the Bogofilter mailing list