From 33d3ea2bdd3804fdbabb08d2ec491772a6c09bd7 Mon Sep 17 00:00:00 2001 From: lebel Date: Fri, 13 Dec 2002 21:40:25 +0000 Subject: [PATCH] update to the bmf mini-howto; from MAINTAINER --- mail/bmf/files/OpenBSD-bmf-mini-howto.html | 63 ++++++++++++---------- 1 file changed, 35 insertions(+), 28 deletions(-) diff --git a/mail/bmf/files/OpenBSD-bmf-mini-howto.html b/mail/bmf/files/OpenBSD-bmf-mini-howto.html index 096a2c2cc6c..ef4ad130b7c 100644 --- a/mail/bmf/files/OpenBSD-bmf-mini-howto.html +++ b/mail/bmf/files/OpenBSD-bmf-mini-howto.html @@ -12,13 +12,12 @@

Before you start to use bmf it is a good thing to know a little bit about the theoretical background of -Bayesian spamfiltering. + Bayesian spamfiltering. -

Basic installation:

+

Training bmf:

-

After installing the port put this at the top of your - .procmailrc. +

Lets take a look at this basic .procmailrc example.

 :0fw
@@ -32,43 +31,49 @@ EXITCODE=$?
 
 :0:
 * ^X-Spam-Status: Yes
-zspam # This is the mailbox where all spam goes.
+zspam # This is the mailbox where all spam goes. -

Now you have to tell bmf the difference between spam and non-spam messages. +:0w +inbox # This is your inbox + + +

bmf will now sort your mail in a spam and non-spam folder. Training + bmf means you have to tell it when it has made a mistake. As an example you can add these shortcuts to your .muttrc

 macro index <f3> "|bmf -S\n<save-message>=zspam\n" "SPAM"
-macro index <f4> "|bmf -N\n<save-message>=Maildir\n" "NO SPAM"
+macro index <f4> "|bmf -N\n<save-message>=inbox\n" "NOT SPAM"
 macro pager <f3> "|bmf -S\n<save-message>=zspam\n" "SPAM"
-macro pager <f4> "|bmf -N\n<save-message>=Maildir\n" "NO SPAM"
+macro pager <f4> "|bmf -N\n<save-message>=inbox\n" "NOT SPAM"
 
-

Now you can press the F3-button to tell bmf a message in your inbox - is spam ( bmf -S ) and move it to your - spam-folder. - +

Now you can press the F3 button to tell bmf a message in your inbox + is spam ( bmf -S ) and move it to your + spam-folder. If you find a non-spam message in your spam-folder you + can press F4 and bmf will unregister the message as spam and put it + in your normal mailfolder.

Feeding a spam-archive to bmf:

To speed up the process of feeding the bmf-database you can also download a recent spam archive - and run the files in the archive through the following oneliner: + and run the files in the archive through the following one-liner:

for i in * ; do bmf -s -i $i; done
-

This method is not recommended by the author since the headers of a - message are also taken in account and the headers of the messages - from a spam-archive do not match yours, but I had good results with +

This method is not recommended by the author since the headers of a + message are also taken in account. And the headers of the messages + from a spam-archive do not match yours. But I had good results with this method. -

Mixing with spamassassin:

+

Mixing with SpamAssassin:

You can also mix bmf with - spamassassin. - bmf is much lighter than spamassassin but spamassassin does not have - to be trained. You can actually use spamassassin to train bmf. Change + SpamAssassin. + bmf is much lighter than spamassassin but SpamAssassin does not have + to be trained. You can actually use SpamAssassin to train bmf. Change your .procmailrc to something like this:

@@ -99,22 +104,24 @@ EXITCODE=$?
 * ^X-Spam-Status: Yes
 {
   :0c
-  | bmf -S
+  | spamassassin -d | bmf -S
   :0
   zspam-sa
 }
-
-

All mail cought by bmf will be send to the zspam-bmf folder. All spam - missed by bmf but cought by spamassassin will be fed to bmf for - training and send to the zspam-sa folder. +:0w +inbox + +

All spam caught by bmf will be send to the zspam-bmf folder. All spam + missed by bmf but caught by SpamAssassin will be fed to bmf for + training and then send to the zspam-sa folder.

Disclaimer:

-

If anything bad happens to your email I am not responsible. If you - know improvements to this document please send them to the maintainer - of this port. +

If anything bad happens to your email I am not responsible. If you + have any improvements to this document please send them to the + maintainer of this port.