On Monday 24 March 2014 12:18:05 Tom Hendrikx wrote:
> On 03/24/2014 12:14 PM, Nuno Fernandes wrote:
> > On Thursday 20 March 2014 07:50:50 Matt Kettler wrote:
> >>> Does this do it?
> >>> 
> >>> score AWL 0
> >>> meta LOCAL_SCORE_AWL     AWL  &&  !URIBL_DBL_SPAM
> >>> score LOCAL_SCORE_AWL    -10
> >>> 
> >>> where -10 is whatever score AWL usually has (I forget)
> >> 
> >> AWL has a variable score, so you can't negate it by a fixed-score rule..
> >> Fundamentally, it is a past-history based score averaging system, hence
> >> the scores for it constantly change.
> > 
> > That's why i would like to remove it in certain scenarios. If it the mail
> > hits my local RBL i would like to remove AWL all together.
> > 
> > Guess i will have to hack AWL.pm :(
> > 
> > Thanks,
> > Nuno Fernandes
> 
> If the rbl gets preference above spamassassin scoring, then why don't
> you just implement the rbl as a separate check in your mta, and make the
> mta reject/quarantine the message without consulting spamassassin at
> all? Just an idea;)
> 
> Tom

Hello,

You are correct but the rbl in the mta (in my postfix configuration) would 
bounce the email to the sender. My spamassassin+amavis quarantines it so that 
the user can release it later on.

Nevertheless i think the following one liner would do the trick (have to test 
it though):

--- Mail/SpamAssassin/Plugin/AWL.pm.orig        2014-03-24 11:31:18.000000000 
+0000
+++ Mail/SpamAssassin/Plugin/AWL.pm     2014-03-24 11:31:20.000000000 +0000
@@ -437,6 +437,7 @@
       # or if the test is marked as "noautolearn"
       next if !$scores->{$test};
       next if exists $tflags->{$test} && $tflags->{$test} =~ /\bnoautolearn\b/;
+      return 0 if $tflags->{$test} =~ /\bnoawl\b/;
       $points += $scores->{$test};
     }

If some other test (that has score!=0) has the tflag noawl, this plugin  
returns immediately. 

Any ideas or problems is this one liner?

Thanks,
Nuno Fernandes

-- 

Reply via email to