procmail & 3-state configuration

Matt Garretson mattg at assembly.state.ny.us
Mon Dec 22 19:43:47 CET 2003


Dave Lovelace wrote:

> what I'd like
> to do is use 3-state classification, route spam (high values) to one file
> (which I'd glance through as I now do), unsures to a second file (to be
> really looked at), and good mail (low values) to be delivered as usual.


I do pretty much the same thing.  With bogofilter configged for
3-state classification, you don't need to process its return code;
in passthru mode, the X-Bogosity: header it inserts tells you
which of the 3 states it ended up in.   Try something like this
(and specify both spam_cutoff AND ham_cutoff in your bogofilter.cf) :

    :0fw
    | /usr/local/bin/bogofilter -e -p
    :0e
    {
      EXITCODE=75
      HOST
    }

    BOGOSITY

    :0
    * ^X-Bogosity: \/.*
    { BOGOSITY=${MATCH} }

    :0:
    * BOGOSITY ?? ^^Yes
    /var/spool/mail/bogo.spam

    :0E:
    * BOGOSITY ?? ^^Unsure
    /var/spool/mail/bogo.unsure

    # If message gets to this point, it is ham and will be
    # delivered normally.

    ## Uncomment next recipe if you want to keep copies
    ## of ham in a central location for later training:
    ## :0c:
    ## /var/spool/mail/bogo.ham








More information about the Bogofilter mailing list