Re: [exim] spam_score_int is not set even the mail is scanne…

Góra strony
Delete this message
Reply to this message
Autor: Jakob Hirsch
Data:  
Dla: Peter
CC: exim-users
Temat: Re: [exim] spam_score_int is not set even the mail is scanned
On 09.01.2010 23:54, Peter wrote:

> thanks a lot Kirill, Heiko and Ted for your help. I got a little bit
> deeper. I don't want to scan the email in the ACL because I can't train the
> bayes-filter user-specific in ACL. In ACL I can only use a bayes-filter for
> one "system-wide" user.


Using user-specific content scanning settings is a common problem, I
think there are some solutions in the wiki.

> So I took Kirill's hint, that it's possible to read $spam_score_int
> directly from the mail-header after the mail was scanned. I was trying
>
> -----
> condition = ${if >{$header_X-Spam-Score}{100}{1}{0}}
> in the ditch_spam-Router but I got an error "failed to expand condition".


RTFM: "If the following character is white space, the terminating colon
may be omitted, but this is not recommended, because you may then forget
it when it is needed."
I.e., you need to use "$h_X-Spam-Score:".
Note that SA's X-Spam-Score usually contains something like "-2.0 (--)",
so you need to extract the first value. And it's not the same as you
would get in $spam_score_int (Exim cannot handle float), so you have to
find a solution for that, too.