From 473e3926fd00986dfd47abf27b4bcfed9db68e1b Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Thu, 15 Jun 2006 21:27:55 +0000 Subject: Do spam classification right here, 3 git-svn-id: svn+ssh://asteria.noreply.org/svn/weaselutils/trunk@131 bc3d92e2-beff-0310-a7cd-cc87d7ac0ede --- split-mailman-mails-and-discard-and-save | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'split-mailman-mails-and-discard-and-save') diff --git a/split-mailman-mails-and-discard-and-save b/split-mailman-mails-and-discard-and-save index 7fc175f..fd7ad93 100755 --- a/split-mailman-mails-and-discard-and-save +++ b/split-mailman-mails-and-discard-and-save @@ -13,7 +13,11 @@ def check_maildir(d) true end - +# usually only mails that are tagges as spam by SA and bogofilter +# are automatically discared +# mails with an SA score over this are however discarded even +# if bogo is unsure or says ham +SA_SCORE_SUFFICIENT = 10.0 OUTBOX = "mail/outbox" @@ -219,7 +223,7 @@ def process_mail(filename) elsif sa_class == "Spam" and bogo_class == "Spam" store_in_maildir(MAIL_PROCESSED_SPAM, message) discard(cookie, request_address) - elsif sa_class == "Spam" and sa_score > 10 # but bogo did not match + elsif sa_class == "Spam" and sa_score > SA_SCORE_SUFFICIENT # but bogo did not match store_in_maildir(SPAMLEARN, held_part) # so we let it learn it store_in_maildir(MAIL_PROCESSED_SPAM, message) discard(cookie, request_address) -- cgit v1.2.3