Spamscore rule for between numbers

Julian Field MailScanner at ecs.soton.ac.uk
Mon Mar 8 11:50:24 GMT 2010



On 08/03/2010 11:12, Michael Mansour wrote:
> Hi Jules,
>
> --- On Mon, 8/3/10, Julian Field<MailScanner at ecs.soton.ac.uk>  wrote:
>
>    
>> From: Julian Field<MailScanner at ecs.soton.ac.uk>
>> Subject: Re: Spamscore rule for between numbers
>> To: "MailScanner discussion"<mailscanner at lists.mailscanner.info>
>> Received: Monday, 8 March, 2010, 8:23 PM
>>
>> On 05/03/2010 23:06, Michael Mansour wrote:
>>      
>>> Hi,
>>>
>>> I'm looking at writing a spamassassin.rule.actions
>>>        
>> rule to say:
>>      
>>> "if the score is between 10 and 20 do ..."
>>>
>>> Looking at the instructions:
>>>
>>> # You can also trigger actions on the spam score of
>>>        
>> the message. You can
>>      
>>> # compare the spam score with a number and cause this
>>>        
>> to trigger an action.
>>      
>>> # For example, instead of a SA_RULENAME you can
>>>        
>> specify
>>      
>>> # SpamScore>number or SpamScore>=number or
>>>        
>> SpamScore==number or
>>      
>>> # SpamScore<number or SpamScore<=number
>>> # where "number" is the threshold value you are
>>>        
>> comparing it against.
>>      
>>> # So you could have a rule/action pair that looks
>>>        
>> like
>>      
>>> #
>>>        
>>      SpamScore>25=>delete
>>      
>>> I'm not sure I can actually do this, since I want
>>>        
>> something like:
>>      
>>> To: *@* SpamScore<20 and SpamScore>10=>store,
>>>        
>> forward ...
>>      
>>> Any ideas on how I can write a rule to say between 10
>>>        
>> and 20 ?
>>      
>>>
>>>        
>> Do it in 2 rules.
>> To: default SpamScore>=10=>store,forward user at domain.com
>> SpamScore>20=>not-store, not-forward user at domain.com
>> So 1 set of actions at 10 and above, and a different set
>> above 20 which
>> cancel out the set at 10 and above.
>>      
> Ok, I've added this rule:
>
> To: default SpamScore>10=>store,not-deliver,forward normalspam at domain.com SpamScore>20=>store,not-deliver,forward highspam at domain.com
>
> So that says anything above 10 (up to 20) goes to normalspam at domain.com while anything above 20 goes to highspam at domain.com
>
> All on the one line. Does that look ok?
>    
You probably need to add a "not-forward normalspam at domain.com" to the 
end of the >20 bit of the rule, or else it will send high spam to that 
address as well.
> Thanks.
>
> Michael.
>
>    
>> Jules
>>
>> -- 
>> Julian Field MEng CITP CEng
>> www.MailScanner.info
>> Buy the MailScanner book at www.MailScanner.info/store
>>
>> Need help customising MailScanner?
>> Contact me!
>> Need help fixing or optimising your systems?
>> Contact me!
>> Need help getting you started solving new requirements from
>> your boss?
>> Contact me!
>>
>> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415
>> B654
>> Follow me at twitter.com/JulesFM and
>> twitter.com/MailScanner
>>
>>
>> -- 
>> This message has been scanned for viruses and
>> dangerous content by MailScanner, and is
>> believed to be clean.
>>
>> -- 
>> MailScanner mailing list
>> mailscanner at lists.mailscanner.info
>> http://lists.mailscanner.info/mailman/listinfo/mailscanner
>>
>> Before posting, read http://wiki.mailscanner.info/posting
>>
>> Support MailScanner development - buy the book off the
>> website!
>>
>>      
>
>
>    

Jules

-- 
Julian Field MEng CITP CEng
www.MailScanner.info
Buy the MailScanner book at www.MailScanner.info/store

Need help customising MailScanner?
Contact me!
Need help fixing or optimising your systems?
Contact me!
Need help getting you started solving new requirements from your boss?
Contact me!

PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
Follow me at twitter.com/JulesFM and twitter.com/MailScanner


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



More information about the MailScanner mailing list