Re: [Exim] spamc and exim

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Peter Bowyer
Date:  
À: exim-users
Sujet: Re: [Exim] spamc and exim
Odhiambo G. Washington <wash@???> wrote:
> * Bruce Richardson <itsbruce@???> [20040321 18:04]: wrote:
>> --
>> On Sun, Mar 21, 2004 at 07:52:44AM -0500, Frank DeChellis wrote:
>>> Hi.
>>>
>>> We have Exim 4.2 and SpamAssassin 2.63. I tried using this entry
>>> in my ACL
>>>
>>> warn    message        = X-Spam-Score: $spam_score ($spam_bar)
>>>           condition      = ${if <{$message_size}{50k}{1}{0}}
>>>           spam           = nobody:true

>>>
>>> to limit the size of the files checked by spamassassin to 50k, but
>>> she's a no seem a to work.
>>>
>> [snip]
>>> Personally, I thought the ACL entry above would work, and a few
>>> guys have confirmed that it should...but that's another question
>>> for another day.
>>
>> If you read the Exiscan documentation, it tells you that any
>> conditions have to be placed into the right hand side of the "spam"
>> modifier. If the right hand side evaluates to 0 or false, no
>> scanning is done. So just merge your condition and spam lines.
>
> I don't quite understand what you are telling the guy here. His rules
> are correct! His problems are elsewere, really.


No, they're not. The 'condtion' clause in the ACL above doesn't control
whether the message gets sent to SA or not - it is evaluated after the
message was scanned and controls the 'warn' clause - hence its usual use for
checking the returned $spam_score before messing with headers or whatever.

If you want to place a condition on whether the message gets scanned, you
need to do what Bruce suggests and put an expansion (maybe a $if{ )in the
'spam=' clause that evaluates to false or zero to prevent scanning, or to
'nobody:true' to cause scanning to take place.

Something like this (untested):

spam = ${if <{$message_size}{50k}{'nobody:true'}{0}}

Peter