[exim] Very weird Spamassassin error, $spam_score and $spam_…

Pàgina inicial
Delete this message
Reply to this message
Autor: Stian Jordet
Data:  
A: exim-users
Assumpte: [exim] Very weird Spamassassin error, $spam_score and $spam_report gives different score.
Hi,

I have with great luck been using Exim and Spamassassin for a while, but
recently I discovered something very weird. Look at this (excerpt from
the headers):

X-Spam-Score: 3.0
X-Spam-Status: No, score=2.9 required=3.0 tests=LONGWORDS autolearn=no version=3.1.0
X-Spam-Flag: YES
X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on buick.jordet.net

How on earth can it claim in the second line that the score is 2.9 when
it just has said 3.0? This is from my config file:

SPAM_ACL = ${lookup ldap {LDAPTYPE://LDAPSERVER/ou=People,dc=jordet?uid?sub?(&(objectClass=inetLocalMailRecipient)\
             (mailLocalAddress=${quote_ldap:${sg{$recipients}{\N(\+.*?\@)\N}{@}}}))}{$value}{\
           ${lookup ldap {LDAPTYPE://LDAPSERVER/ou=Virtual,dc=jordet?cn?sub?(&(objectClass=inetLocalMailRecipient)\
           (mailLocalAddress=${quote_ldap:${sg{$recipients}{\N(\+.*?\@)\N}{@}}}))}{$value}{\
           ${lookup ldap {LDAPTYPE://LDAPSERVER/ou=People,dc=jordet?uid?sub?(&(objectClass=inetLocalMailRecipient)\
           (mailLocalAddress=${quote_ldap:@${extract{2}{@}{$recipients}}}))}{$value}{nobody}}}}}}



warn message = X-Spam-Score: $spam_score
condition = ${if <{$message_size}{500k}{1}{0}}
spam = SPAM_ACL/defer_ok

warn message = X-Spam-Status: $spam_report
condition = ${if <{$message_size}{500k}{1}{0}}
spam = SPAM_ACL:true/defer_ok

warn message = X-Spam-Flag: YES
condition = ${if <{$message_size}{500k}{1}{0}}
spam = SPAM_ACL/defer_ok
log_message = Spam: $spam_score

warn message = X-Spam-Checker-Version: SpamAssassin ${perl{version}} (${perl{subversion}}) on $primary_hostname
spam = SPAM_ACL:true/defer_ok

When looking at the mail log, I can see the SA only scanned the message
once:

Nov 21 21:49:20 buick exim[3474]: 2005-11-21 21:49:20 SMTP connection from [209.132.176.167]:54638 I=[217.8.143.72]:25 (TCP/IP connection count = 1)
Nov 21 21:49:21 buick spamd[3408]: spamd: got connection over /var/run/spamd.sock
Nov 21 21:49:21 buick spamd[3408]: spamd: checking message <008801c5eedc$f7277060$1225a8c0@kittycat> for stianj:0
Nov 21 21:49:22 buick spamd[3408]: spamd: clean message (3.0/3.0) for stianj:0 in 0.5 seconds, 6448 bytes.
Nov 21 21:49:22 buick spamd[3408]: spamd: result: . 2 - LONGWORDS scantime=0.5,size=6448,user=stianj,uid=0,required_score=3.0,rhost=localhost,raddr=127.0.0.1,rport=/var/run/spamd.sock,mid=<008801c5eedc$f7277060$1225a8c0@kittycat>,autolearn=no
Nov 21 21:49:22 buick exim[26251]: 2005-11-21 21:49:22 1EeIbJ-0006pP-BY H=vger.kernel.org [209.132.176.167]:54638 I=[217.8.143.72]:25 Warning: Spam: 3.0
Nov 21 21:49:22 buick spamd[3365]: prefork: child states: II
Nov 21 21:49:23 buick exim[26251]: 2005-11-21 21:49:23 1EeIbJ-0006pP-BY <= linux-kernel-owner+liste=40jordet.net-S932448AbVKUUsu@??? H=vger.kernel.org [209.132.176.167]:54638 I=[217.8.143.72]:25 P=esmtp S=6536 id=008801c5eedc$f7277060$1225a8c0@kittycat from <linux-kernel-owner+liste=40jordet.net-S932448AbVKUUsu@???> for liste@???
Nov 21 21:49:23 buick exim[26257]: 2005-11-21 21:49:23 1EeIbJ-0006pP-BY => stianj <liste@???> F=<linux-kernel-owner+liste=40jordet.net-S932448AbVKUUsu@???> P=<linux-kernel-owner+liste=40jordet.net-S932448AbVKUUsu@???> R=procmail T=procmail_pipe S=6799 QT=2s DT=0s
Nov 21 21:49:23 buick exim[26257]: 2005-11-21 21:49:23 1EeIbJ-0006pP-BY Completed QT=2s
Nov 21 21:49:23 buick exim[26251]: 2005-11-21 21:49:23 SMTP connection from vger.kernel.org [209.132.176.167]:54638 I=[217.8.143.72]:25 closed by QUIT

Last, this is from my /etc/spamassassin/local.cf:

clear_report_template
report _YESNO_, score=_SCORE_ required=_REQD_ tests=_TESTS(,)_ autolearn=_AUTOLEARN_ version=_VERSION_

Could this be a problem with my setup, a bug in exim or a bug in SA?
Hope someone can share some insight on this.

Best regards,
Stian