You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Leon Kolchinsky <lk...@univ.haifa.ac.il> on 2006/11/26 14:55:47 UTC

optional score in local.cf is not working

Hello All,

I've upgraded to:
amavisd-new-2.4.4-4
spamassassin-3.1.7-3
from:
amavisd-new-20030616p9-3.6
spamassassin-2.64-3.7

These are optional scores in my local.cf:

## Optional Score
score ROUND_THE_WORLD 0
score SUBJ_ILLEGAL_CHARS 0
score HEAD_ILLEGAL_CHARS 0
score FORGED_HOTMAIL_RCVD2 0
score FORGED_YAHOO_RCVD 0
score SUBJ_ALL_CAPS 0
score MISSING_SUBJECT 0
score DNS_FROM_RFC_POST 0
score DNS_FROM_RFC_ABUSE 0

The problem is that it seems that I still get scorings for the above rules :(

DNS_FROM_RFC_ABUSE=0.2


See below example of such spam e-mail:
---------------------------------------
Return-Path: <MA...@mydomain.ac.il>
Received: from mydomain.ac.il ([unix socket])
	by mydomain.ac.il (Cyrus v2.2.3) with LMTP; Sun, 26 Nov 2006 15:43:32 +0200
X-Sieve: CMU Sieve 2.2
Received: from localhost (localhost [127.0.0.1])
	by mydomain.ac.il (Postfix) with ESMTP id 739CF12886D
	for <sp...@edu.haifa.ac.il>; Sun, 26 Nov 2006 15:43:32 +0200 (IST)
X-Envelope-From: <vf...@mchsi.com>
X-Envelope-To: <nl...@mydomain.ac.il>
X-Quarantine-ID: <a6-A-NiMWaoS>
X-Amavis-Alert: BAD HEADER Non-encoded 8-bit data (char 88 hex): Subject:
	\2101000 FREE in We...
X-Spam-Flag: YES
X-Spam-Score: 44.281
X-Spam-Level: ********************************************
X-Spam-Status: Yes, score=44.281 tag=-999 tag2=5 kill=5 tests=[BAYES_99=3.5,
	DATE_IN_PAST_96_XX=2.02, DNS_FROM_RFC_ABUSE=0.2,
	DNS_FROM_RFC_WHOIS=1.447, FROM_LOCAL_NOVOWEL=2.861,
	HELO_DYNAMIC_IPADDR2=3.818, HTML_50_60=0.134, HTML_MESSAGE=0.001,
	HTML_TAG_BALANCE_HEAD=1.447, MIME_HTML_ONLY=0.001,
	RAZOR2_CF_RANGE_51_100=0.5, RAZOR2_CF_RANGE_E4_51_100=1.5,
	RAZOR2_CF_RANGE_E8_51_100=1.5, RAZOR2_CHECK=0.5,
	RCVD_IN_BL_SPAMCOP_NET=1.558, RCVD_IN_NJABL_DUL=1.946,
	RCVD_IN_SORBS_DUL=2.046, RCVD_IN_XBL=3.897, URIBL_AB_SURBL=3.812,
	URIBL_JP_SURBL=4.087, URIBL_OB_SURBL=3.008, URIBL_SC_SURBL=4.498]
Received: from mydomain.ac.il ([127.0.0.1])
	by localhost (mydomain.ac.il [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id a6-A-NiMWaoS for <nl...@mydomain.ac.il>;
	Sun, 26 Nov 2006 15:43:29 +0200 (IST)
Received: from 12-215-32-57.client.mchsi.com (12-215-32-57.client.mchsi.com [12.215.32.57])
	by mydomain.ac.il (Postfix) with ESMTP id 3075B1F951
	for <nl...@construct.haifa.ac.il>; Sun, 26 Nov 2006 15:43:23 +0200 (IST)
From: "wont realize" <vf...@mchsi.com>
To: nlevin@construct.haifa.ac.il
Subject: X1000 FREE in Welcome Bonuses
Date:	Thu, 26 Oct 2006 08:48:39 +0500
MIME-Version: 1.0
Content-Type: multipart/related;
	boundary="----=_NextPart_000_0002_01C6F8DB.88943B60"
X-Mailer: Microsoft Office Outlook, Build 11.0.5510
Thread-Index: Acb424iUdIWYHggsSheZUsiBH1MRuA==
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869
Message-Id: <8E...@mchsi.com>



Could it be because I'm still using "old stile" amavisd.conf?
Any help?



Best Regards,
Leon Kolchinsky

RE: optional score in local.cf is not working

Posted by Dan Horne <da...@taisweb.net>.
As has been stated multiple times, Amavisd-new does NOT use spamd.  Just
try out this little test, m'kay?  Stop spamd.  Don't restart it, just
stop it.  Now see if amavisd is still scanning for spam.  What's that?
It is?  Whodathunkit!  That's why you need to restart amavisd to reload
changed config files.

You should stop spamd from starting automatically, as it is just a waste
of resources since you are using amavisd-new.

> -----Original Message-----
> From: Leon Kolchinsky [mailto:lkolchin@univ.haifa.ac.il] 
> Sent: Wednesday, November 29, 2006 8:53 AM
> To: Nigel Frankcom; users@spamassassin.apache.org
> Subject: RE: optional score in local.cf is not working
> 
> Hi,
> 
> OK.
> I did some manual tests and indeed changes in local.cf only 
> catching then I restart amavis.
> 
> # /etc/init.d/amavis restart
> Shutting down virus-scanner (amavisd-new):Daemon [9905] 
> terminated by SIGTERM
>                                                               
>                                                     done
> Starting virus-scanner (amavisd-new):                         
>                                                     done
> 
> When I restart only spamd no change in local.cf is catching.
> 
> 
> I don't really understand why?
> 
> Mark Martinec said that "amavisd-new can't call spamd" 
> 
> So, let me get this straight:
> -----------------------------
> This is how I see the work of amavis+spamd+clamd:
> 
> 1. As I see it amavis talk to spamd (spamassassin) and clamd 
> (ClamAV) via appropriate sockets or TCP ports.
> In my case -
> To clamd via /var/lib/clamav/clamd-socket (I can see it in 
> amavisd.conf) To spamd ? (I don't know how to check it)
> 
> 2. Any configuration change I make to clamd and spamd take 
> power only when I restart the deamons themselves.
> 
> 3. But according to Matt Kettler response and my testings, 
> any change to local.cf require amavis restart.
> 
> # /etc/init.d/amavis restart
> Shutting down virus-scanner (amavisd-new):Daemon [9905] 
> terminated by SIGTERM
>                                                               
>                                                     done
> Starting virus-scanner (amavisd-new):                         
>                                                     done
> 
> 
> What is going on?
> Where I can validate config options of amavis to make sure 
> the way it works?
> 
> 
> 
> P.S.:
> 
> 
> This is taken from /etc/init.d/amavis:
> --------------------------------------
> AMAVISD_BIN=/usr/sbin/amavisd
> AMAVIS_MILTER_BIN=/usr/sbin/amavis-milter
>         echo -n "Starting virus-scanner (amavisd-new):"
>         $AMAVISD_BIN start
>         if ! checkproc amavisd; then
>            rc_failed 7
>         fi
>         rc_status -v
>         if [ "$AMAVIS_SENDMAIL_MILTER" == "yes" ]; then
>             rc_reset
>             echo -n "Starting amavis-milter:"
>             startproc -u vscan $AMAVIS_MILTER_BIN -p 
> local:/var/run/amavis/amavis-milter.sock > /dev/null 2>&1
>             rc_status -v
> 
> 
> This is taken from /etc/init.d/spamd:
> -------------------------------------
> # Short-Description: Start the spamassassin daemon 
> SPAMD_BIN=/usr/sbin/spamd PIDFILE=/var/run/spamd.pid 
> startproc -p $PIDFILE $SPAMD_BIN $SPAMD_ARGS -r $PIDFILE
> 
> 
> This is taken from /etc/amavisd.conf:
> -------------------------------------
> @av_scanners = (
> ### http://www.clamav.net/
> ['ClamAV-clamd',
>   \&ask_daemon, ["CONTSCAN {}\n", "/var/lib/clamav/clamd-socket"],
>   qr/\bOK$/, qr/\bFOUND$/,
>   qr/^.*?: (?!Infected Archive)(.*) FOUND$/ ],
> 
> 
> 
> -----Original Message-----
> From: Nigel Frankcom [mailto:nigel@blue-canoe.net]
> Sent: Wednesday, November 29, 2006 10:21 AM
> To: users@spamassassin.apache.org
> Subject: Re: optional score in local.cf is not working
> 
> On Wed, 29 Nov 2006 10:10:58 +0200, "Leon Kolchinsky"
> <lk...@univ.haifa.ac.il> wrote:
> 
> >Hi,
> >
> >I thought I was wrong and "amavis restart" didn't really 
> helped there, but there is an update for this problem I had 
> with configuration in local.cf not catching.
> >
> >It seems that only when I do /etc/init.d/amavis restart, all 
> configs in local.cf are coming intact.
> >
> >I've used to an old version of amavis and SA on Suse, where 
> you would only do changes to local.cf and "spamd restart".
> >
> >1) So, my question is - Is this a normal behavior? 
> >2) For every change in local.cf should I do now only "amavis 
> restart" and no "spamd restart"?
> >
> >
> >
> >Regards,
> >Leon
> >
> >-----Original Message-----
> >From: Mark Martinec [mailto:Mark.Martinec+sa@ijs.si]
> >Sent: Sunday, November 26, 2006 10:54 PM
> >To: users@spamassassin.apache.org
> >Subject: Re: optional score in local.cf is not working
> >
> >On Sunday November 26 2006 20:25, Matt Kettler wrote:
> >> >> Erm.. are you sure? I thought amavisd-new called SA directly at 
> >> >> the API layer, not via spamd...
> >> I didn't even realize amavis *could* use spamd, every 
> amavis person 
> >> I've talked to on the list isn't using it.
> >
> >amavisd-new can't call spamd, there is no configuration option to do 
> >so, and no code to support it.
> >
> >spamc/spamd could be used (if desired/needed) by 
> implementing the usual 
> >SA standalone setup, and disabling spam checking in amavisd.
> >
> >  Mark
> 
> As far as I am aware any setting changes in the local.cf need 
> a restart of spamd. Whether or not amavis does this for you I 
> don't know. I do recall someone recently mentioning that the 
> Amavis doesn't give enough time and/or wait for the return 
> from spamd. Though this may not be at all related to your issue.
> 
> For a simple test. Make a change and manually restart 
> spamassassin, then undo the change, restart just amavis and 
> see if amavis picks it up?
> 
> HTH
> 
> Kind regards
> 
> Nigel
> 

CONFIDENTIALITY NOTICE:
This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message.
 
SPAM-FREE 1.0(2476)



RE: optional score in local.cf is not working

Posted by Leon Kolchinsky <lk...@univ.haifa.ac.il>.
Hi,

OK.
I did some manual tests and indeed changes in local.cf only catching then I restart amavis.

# /etc/init.d/amavis restart
Shutting down virus-scanner (amavisd-new):Daemon [9905] terminated by SIGTERM
                                                                                                                  done
Starting virus-scanner (amavisd-new):                                                                             done

When I restart only spamd no change in local.cf is catching.


I don’t really understand why?

Mark Martinec said that "amavisd-new can't call spamd" 

So, let me get this straight:
-----------------------------
This is how I see the work of amavis+spamd+clamd:

1. As I see it amavis talk to spamd (spamassassin) and clamd (ClamAV) via appropriate sockets or TCP ports.
In my case - 
To clamd via /var/lib/clamav/clamd-socket (I can see it in amavisd.conf)
To spamd ? (I don't know how to check it)

2. Any configuration change I make to clamd and spamd take power only when I restart the deamons themselves.

3. But according to Matt Kettler response and my testings, any change to local.cf require amavis restart.

# /etc/init.d/amavis restart
Shutting down virus-scanner (amavisd-new):Daemon [9905] terminated by SIGTERM
                                                                                                                  done
Starting virus-scanner (amavisd-new):                                                                             done


What is going on?
Where I can validate config options of amavis to make sure the way it works?



P.S.:


This is taken from /etc/init.d/amavis:
--------------------------------------
AMAVISD_BIN=/usr/sbin/amavisd
AMAVIS_MILTER_BIN=/usr/sbin/amavis-milter
        echo -n "Starting virus-scanner (amavisd-new):"
        $AMAVISD_BIN start
        if ! checkproc amavisd; then
           rc_failed 7
        fi
        rc_status -v
        if [ "$AMAVIS_SENDMAIL_MILTER" == "yes" ]; then
            rc_reset
            echo -n "Starting amavis-milter:"
            startproc -u vscan $AMAVIS_MILTER_BIN -p local:/var/run/amavis/amavis-milter.sock > /dev/null 2>&1
            rc_status -v


This is taken from /etc/init.d/spamd:
-------------------------------------
# Short-Description: Start the spamassassin daemon
SPAMD_BIN=/usr/sbin/spamd
PIDFILE=/var/run/spamd.pid
startproc -p $PIDFILE $SPAMD_BIN $SPAMD_ARGS -r $PIDFILE


This is taken from /etc/amavisd.conf:
-------------------------------------
@av_scanners = (
### http://www.clamav.net/
['ClamAV-clamd',
  \&ask_daemon, ["CONTSCAN {}\n", "/var/lib/clamav/clamd-socket"],
  qr/\bOK$/, qr/\bFOUND$/,
  qr/^.*?: (?!Infected Archive)(.*) FOUND$/ ],



-----Original Message-----
From: Nigel Frankcom [mailto:nigel@blue-canoe.net] 
Sent: Wednesday, November 29, 2006 10:21 AM
To: users@spamassassin.apache.org
Subject: Re: optional score in local.cf is not working

On Wed, 29 Nov 2006 10:10:58 +0200, "Leon Kolchinsky"
<lk...@univ.haifa.ac.il> wrote:

>Hi,
>
>I thought I was wrong and "amavis restart" didn't really helped there, but there is an update for this problem I had with configuration in local.cf not catching.
>
>It seems that only when I do /etc/init.d/amavis restart, all configs in local.cf are coming intact.
>
>I've used to an old version of amavis and SA on Suse, where you would only do changes to local.cf and "spamd restart".
>
>1) So, my question is - Is this a normal behavior? 
>2) For every change in local.cf should I do now only "amavis restart" and no "spamd restart"?
>
>
>
>Regards,
>Leon
>
>-----Original Message-----
>From: Mark Martinec [mailto:Mark.Martinec+sa@ijs.si] 
>Sent: Sunday, November 26, 2006 10:54 PM
>To: users@spamassassin.apache.org
>Subject: Re: optional score in local.cf is not working
>
>On Sunday November 26 2006 20:25, Matt Kettler wrote:
>> >> Erm.. are you sure? I thought amavisd-new called SA directly at the API
>> >> layer, not via spamd...
>> I didn't even realize amavis *could* use spamd, every amavis person I've
>> talked to on the list isn't using it.
>
>amavisd-new can't call spamd, there is no configuration option to do so,
>and no code to support it.
>
>spamc/spamd could be used (if desired/needed) by implementing the usual SA 
>standalone setup, and disabling spam checking in amavisd.
>
>  Mark

As far as I am aware any setting changes in the local.cf need a
restart of spamd. Whether or not amavis does this for you I don't
know. I do recall someone recently mentioning that the Amavis doesn't
give enough time and/or wait for the return from spamd. Though this
may not be at all related to your issue.

For a simple test. Make a change and manually restart spamassassin,
then undo the change, restart just amavis and see if amavis picks it
up?

HTH

Kind regards

Nigel

Re: optional score in local.cf is not working

Posted by Nigel Frankcom <ni...@blue-canoe.net>.
On Wed, 29 Nov 2006 10:10:58 +0200, "Leon Kolchinsky"
<lk...@univ.haifa.ac.il> wrote:

>Hi,
>
>I thought I was wrong and "amavis restart" didn't really helped there, but there is an update for this problem I had with configuration in local.cf not catching.
>
>It seems that only when I do /etc/init.d/amavis restart, all configs in local.cf are coming intact.
>
>I've used to an old version of amavis and SA on Suse, where you would only do changes to local.cf and "spamd restart".
>
>1) So, my question is - Is this a normal behavior? 
>2) For every change in local.cf should I do now only "amavis restart" and no "spamd restart"?
>
>
>
>Regards,
>Leon
>
>-----Original Message-----
>From: Mark Martinec [mailto:Mark.Martinec+sa@ijs.si] 
>Sent: Sunday, November 26, 2006 10:54 PM
>To: users@spamassassin.apache.org
>Subject: Re: optional score in local.cf is not working
>
>On Sunday November 26 2006 20:25, Matt Kettler wrote:
>> >> Erm.. are you sure? I thought amavisd-new called SA directly at the API
>> >> layer, not via spamd...
>> I didn't even realize amavis *could* use spamd, every amavis person I've
>> talked to on the list isn't using it.
>
>amavisd-new can't call spamd, there is no configuration option to do so,
>and no code to support it.
>
>spamc/spamd could be used (if desired/needed) by implementing the usual SA 
>standalone setup, and disabling spam checking in amavisd.
>
>  Mark

As far as I am aware any setting changes in the local.cf need a
restart of spamd. Whether or not amavis does this for you I don't
know. I do recall someone recently mentioning that the Amavis doesn't
give enough time and/or wait for the return from spamd. Though this
may not be at all related to your issue.

For a simple test. Make a change and manually restart spamassassin,
then undo the change, restart just amavis and see if amavis picks it
up?

HTH

Kind regards

Nigel

Re: optional score in local.cf is not working

Posted by Matt Kettler <mk...@verizon.net>.
Leon Kolchinsky wrote:
> Hi,
>
> I thought I was wrong and "amavis restart" didn't really helped there, but there is an update for this problem I had with configuration in local.cf not catching.
>
> It seems that only when I do /etc/init.d/amavis restart, all configs in local.cf are coming intact.
>
> I've used to an old version of amavis and SA on Suse, where you would only do changes to local.cf and "spamd restart".
>
> 1) So, my question is - Is this a normal behavior? 
>   
Yes. Because amavisd-new uses the API, restarting spamd should have no
affect on it. I don't know why your old version ever used spamd, as it's
highly inefficient for a perl application to do so instead of calling
Mail::SpamAssassin.
> 2) For every change in local.cf should I do now only "amavis restart" and no "spamd restart"?
>   
Yes.. and you should also change your system to not run spamd anymore.

Amavisd-new does not use spamd, so running it is a waste of memory.


RE: optional score in local.cf is not working

Posted by Leon Kolchinsky <lk...@univ.haifa.ac.il>.
Hi,

I thought I was wrong and "amavis restart" didn't really helped there, but there is an update for this problem I had with configuration in local.cf not catching.

It seems that only when I do /etc/init.d/amavis restart, all configs in local.cf are coming intact.

I've used to an old version of amavis and SA on Suse, where you would only do changes to local.cf and "spamd restart".

1) So, my question is - Is this a normal behavior? 
2) For every change in local.cf should I do now only "amavis restart" and no "spamd restart"?



Regards,
Leon

-----Original Message-----
From: Mark Martinec [mailto:Mark.Martinec+sa@ijs.si] 
Sent: Sunday, November 26, 2006 10:54 PM
To: users@spamassassin.apache.org
Subject: Re: optional score in local.cf is not working

On Sunday November 26 2006 20:25, Matt Kettler wrote:
> >> Erm.. are you sure? I thought amavisd-new called SA directly at the API
> >> layer, not via spamd...
> I didn't even realize amavis *could* use spamd, every amavis person I've
> talked to on the list isn't using it.

amavisd-new can't call spamd, there is no configuration option to do so,
and no code to support it.

spamc/spamd could be used (if desired/needed) by implementing the usual SA 
standalone setup, and disabling spam checking in amavisd.

  Mark

RE: optional score in local.cf is not working

Posted by Leon Kolchinsky <lk...@univ.haifa.ac.il>.
Hi,

I've moved to a new syntax style of amavisd.conf for 2.4.4 version (modified sample file) and now all is working.
Restarted amavis and it read the local.cf config now.


Best Regards,
Leon Kolchinsky

-----Original Message-----
From: Mark Martinec [mailto:Mark.Martinec+sa@ijs.si] 
Sent: Sunday, November 26, 2006 10:54 PM
To: users@spamassassin.apache.org
Subject: Re: optional score in local.cf is not working

On Sunday November 26 2006 20:25, Matt Kettler wrote:
> >> Erm.. are you sure? I thought amavisd-new called SA directly at the API
> >> layer, not via spamd...
> I didn't even realize amavis *could* use spamd, every amavis person I've
> talked to on the list isn't using it.

amavisd-new can't call spamd, there is no configuration option to do so,
and no code to support it.

spamc/spamd could be used (if desired/needed) by implementing the usual SA 
standalone setup, and disabling spam checking in amavisd.

  Mark

Re: optional score in local.cf is not working

Posted by Mark Martinec <Ma...@ijs.si>.
On Sunday November 26 2006 20:25, Matt Kettler wrote:
> >> Erm.. are you sure? I thought amavisd-new called SA directly at the API
> >> layer, not via spamd...
> I didn't even realize amavis *could* use spamd, every amavis person I've
> talked to on the list isn't using it.

amavisd-new can't call spamd, there is no configuration option to do so,
and no code to support it.

spamc/spamd could be used (if desired/needed) by implementing the usual SA 
standalone setup, and disabling spam checking in amavisd.

  Mark

Re: optional score in local.cf is not working

Posted by Matt Kettler <mk...@verizon.net>.
Leon Kolchinsky wrote:
>>> 1. AFAIK it is not necessary to restart amavisd-new, after a change in local.cf it is enough to restart spamd.
>>>   
>>>       
>> Erm.. are you sure? I thought amavisd-new called SA directly at the API
>> layer, not via spamd...
>>     
>
> At least this is how it worked on SLES9 with those versions: 
> amavisd-new-20030616p9-3.6
> spamassassin-2.64-3.7
>
>
>   

Ahh, apparently this is a configuration option. However, being higher
performance, most amavis users use Mail::SpamAssassin, not spamd.

I didn't even realize amavis *could* use spamd, every amavis person I've
talked to on the list isn't using it.



RE: optional score in local.cf is not working

Posted by Leon Kolchinsky <lk...@univ.haifa.ac.il>.
>>
>> 1. AFAIK it is not necessary to restart amavisd-new, after a change in local.cf it is enough to restart spamd.
>>   
>Erm.. are you sure? I thought amavisd-new called SA directly at the API
>layer, not via spamd...

At least this is how it worked on SLES9 with those versions: 
amavisd-new-20030616p9-3.6
spamassassin-2.64-3.7




Re: optional score in local.cf is not working

Posted by Matt Kettler <mk...@verizon.net>.
Leon Kolchinsky wrote:
>
> 1. AFAIK it is not necessary to restart amavisd-new, after a change in local.cf it is enough to restart spamd.
>   
Erm.. are you sure? I thought amavisd-new called SA directly at the API
layer, not via spamd...

RE: optional score in local.cf is not working

Posted by Giampaolo Tomassoni <g....@libero.it>.
From: Leon Kolchinsky [mailto:lkolchin@univ.haifa.ac.il]
> 
> 1. AFAIK it is not necessary to restart amavisd-new, after a 
> change in local.cf it is enough to restart spamd.

Most installations runs SA as an amavisd-new module. Spamd is not required in that cases and a change in local.cf do needs amavisd restart in order to take effect.

FWIK, of course.

giampaolo


> 
> 2. spamassassin --lint
> Gives no output so it is OK I guess.
> 
> 3. I've noticed that even whitelist_from_rcvd which worked fine 
> with the old version is now not working, i.e. users in 
> whitelist_from_rcvd now getting spam score enough to go to quarantine.
> 
> 4. spamassassin --lint -D give the following output (as you can 
> see below it reads local.cf: [16694] dbg: config: read file 
> /etc/mail/spamassassin/local.cf):
> 
> [16694] dbg: logger: adding facilities: all
> [16694] dbg: logger: logging level is DBG
> [16694] dbg: generic: SpamAssassin version 3.1.7
> [16694] dbg: config: score set 0 chosen.
> [16694] dbg: util: running in taint mode? yes
> [16694] dbg: util: taint mode: deleting unsafe environment 
> variables, resetting PATH
> [16694] dbg: util: PATH included '/sbin', keeping
> [16694] dbg: util: PATH included '/usr/sbin', keeping
> [16694] dbg: util: PATH included '/usr/local/sbin', keeping
> [16694] dbg: util: PATH included '/root/bin', keeping
> [16694] dbg: util: PATH included '/usr/local/bin', keeping
> [16694] dbg: util: PATH included '/usr/bin', keeping
> [16694] dbg: util: PATH included '/usr/X11R6/bin', keeping
> [16694] dbg: util: PATH included '/bin', keeping
> [16694] dbg: util: PATH included '/usr/games', keeping
> [16694] dbg: util: PATH included '/opt/gnome/bin', keeping
> [16694] dbg: util: PATH included '/opt/kde3/bin', keeping
> [16694] dbg: util: PATH included '/usr/lib/java/jre/bin', keeping
> [16694] dbg: util: final PATH set to: 
> /sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:
> /usr/X11R6/bin:/bin:/usr/games:/opt/gnome/bin:/opt/kde3/bin:/usr/l
> ib/java/jre/bin
> [16694] dbg: message: ---- MIME PARSER START ----
> [16694] dbg: message: main message type: text/plain
> [16694] dbg: message: parsing normal part
> [16694] dbg: message: added part, type: text/plain
> [16694] dbg: message: ---- MIME PARSER END ----
> [16694] dbg: dns: is Net::DNS::Resolver available? yes
> [16694] dbg: dns: Net::DNS version: 0.46
> [16694] dbg: diag: perl platform: 5.008003 linux
> [16694] dbg: diag: module installed: Digest::SHA1, version 2.07
> [16694] dbg: diag: module not installed: Mail::SPF::Query 
> ('require' failed)
> [16694] dbg: diag: module not installed: IP::Country::Fast 
> ('require' failed)
> [16694] dbg: diag: module installed: Razor2::Client::Agent, version 2.82
> [16694] dbg: diag: module not installed: Net::Ident ('require' failed)
> [16694] dbg: diag: module not installed: IO::Socket::INET6 
> ('require' failed)
> [16694] dbg: diag: module installed: IO::Socket::SSL, version 0.95
> [16694] dbg: diag: module installed: Time::HiRes, version 1.52
> [16694] dbg: diag: module installed: DBI, version 1.41
> [16694] dbg: diag: module installed: Getopt::Long, version 2.34
> [16694] dbg: diag: module installed: LWP::UserAgent, version 2.024
> [16694] dbg: diag: module installed: HTTP::Date, version 1.46
> [16694] dbg: diag: module installed: Archive::Tar, version 1.08
> [16694] dbg: diag: module installed: IO::Zlib, version 1.04
> [16694] dbg: diag: module installed: DB_File, version 1.808
> [16694] dbg: diag: module installed: HTML::Parser, version 3.35
> [16694] dbg: diag: module installed: MIME::Base64, version 2.21
> [16694] dbg: diag: module installed: Net::DNS, version 0.46
> [16694] dbg: diag: module installed: Net::SMTP, version 2.26
> [16694] dbg: ignore: using a test message to lint rules
> [16694] dbg: config: using "/etc/mail/spamassassin" for site 
> rules pre files
> [16694] dbg: config: read file /etc/mail/spamassassin/init.pre
> [16694] dbg: config: read file /etc/mail/spamassassin/v310.pre
> [16694] dbg: config: read file /etc/mail/spamassassin/v312.pre
> [16694] dbg: config: using "/usr/share/spamassassin" for sys 
> rules pre files
> [16694] dbg: config: using "/usr/share/spamassassin" for default rules dir
> [16694] dbg: config: read file /usr/share/spamassassin/10_misc.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_advance_fee.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_anti_ratware.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_body_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_compensate.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_dnsbl_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_drugs.cf
> [16694] dbg: config: read file 
> /usr/share/spamassassin/20_fake_helo_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_head_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_html_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_meta_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_net_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_phrases.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_porn.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_ratware.cf
> [16694] dbg: config: read file /usr/share/spamassassin/20_uri_tests.cf
> [16694] dbg: config: read file /usr/share/spamassassin/23_bayes.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_accessdb.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_antivirus.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_body_tests_es.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_body_tests_pl.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_dcc.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_dkim.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_domainkeys.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_hashcash.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_pyzor.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_razor2.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_replace.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_spf.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_textcat.cf
> [16694] dbg: config: read file /usr/share/spamassassin/25_uribl.cf
> [16694] dbg: config: read file /usr/share/spamassassin/30_text_de.cf
> [16694] dbg: config: read file /usr/share/spamassassin/30_text_fr.cf
> [16694] dbg: config: read file /usr/share/spamassassin/30_text_it.cf
> [16694] dbg: config: read file /usr/share/spamassassin/30_text_nl.cf
> [16694] dbg: config: read file /usr/share/spamassassin/30_text_pl.cf
> [16694] dbg: config: read file /usr/share/spamassassin/30_text_pt_br.cf
> [16694] dbg: config: read file /usr/share/spamassassin/50_scores.cf
> [16694] dbg: config: read file /usr/share/spamassassin/60_awl.cf
> [16694] dbg: config: read file /usr/share/spamassassin/60_whitelist.cf
> [16694] dbg: config: read file /usr/share/spamassassin/60_whitelist_dk.cf
> [16694] dbg: config: read file 
> /usr/share/spamassassin/60_whitelist_dkim.cf
> [16694] dbg: config: read file /usr/share/spamassassin/60_whitelist_spf.cf
> [16694] dbg: config: read file 
> /usr/share/spamassassin/60_whitelist_subject.cf
> [16694] dbg: config: using "/etc/mail/spamassassin" for site rules dir
> [16694] dbg: config: read file /etc/mail/spamassassin/FuzzyOcr.cf
> [16694] dbg: config: read file /etc/mail/spamassassin/local.cf
> [16694] dbg: config: using "/root/.spamassassin/user_prefs" for 
> user prefs file
> [16694] dbg: config: read file /root/.spamassassin/user_prefs
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::URIDNSBL 
> from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c)
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::Hashcash 
> from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::Hashcash=HASH(0x928f360)
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::SPF from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::SPF=HASH(0x92a5924)
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::Pyzor from @INC
> [16694] dbg: pyzor: local tests only, disabling Pyzor
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::Pyzor=HASH(0x92b8420)
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::Razor2 from @INC
> [16694] dbg: razor2: local tests only, skipping Razor
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::Razor2=HASH(0x92917fc)
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::SpamCop from @INC
> [16694] dbg: reporter: local tests only, disabling SpamCop
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::SpamCop=HASH(0x92938cc)
> [16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::AWL from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::AWL=HASH(0x9315964)
> [16694] dbg: plugin: loading 
> Mail::SpamAssassin::Plugin::AutoLearnThreshold from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::AutoLearnThreshold=HASH(0x9338db4)
> [16694] dbg: plugin: loading 
> Mail::SpamAssassin::Plugin::WhiteListSubject from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::WhiteListSubject=HASH(0x9329f1c)
> [16694] dbg: plugin: loading 
> Mail::SpamAssassin::Plugin::MIMEHeader from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::MIMEHeader=HASH(0x934bea4)
> [16694] dbg: plugin: loading 
> Mail::SpamAssassin::Plugin::ReplaceTags from @INC
> [16694] dbg: plugin: registered 
> Mail::SpamAssassin::Plugin::ReplaceTags=HASH(0x93439ec)
> [16694] dbg: config: adding redirector regex: 
> /^http:\/\/chkpt\.zdnet\.com\/chkpt\/\w+\/(.*)$/i
> [16694] dbg: config: adding redirector regex: 
> /^http:\/\/www(?:\d+)?\.nate\.com\/r\/\w+\/(.*)$/i
> [16694] dbg: config: adding redirector regex: 
> /^http:\/\/.+\.gov\/(?:.*\/)?externalLink\.jhtml\?.*url=(.*?)(?:&.*)?$/i
> [16694] dbg: config: adding redirector regex: 
> /^http:\/\/redir\.internet\.com\/.+?\/.+?\/(.*)$/i
> [16694] dbg: config: adding redirector regex: 
> /^http:\/\/(?:.*?\.)?adtech\.de\/.*(?:;|\|)link=(.*?)(?:;|$)/i
> [16694] dbg: config: adding redirector regex: 
> m'^http.*?/redirect\.php\?.*(?<=[?&])goto=(.*?)(?:$|[&#])'i
> [16694] dbg: config: adding redirector regex: 
> m'^https?:/*(?:[^/]+\.)?emf\d\.com/r\.cfm.*?&r=(.*)'i
> [16694] dbg: config: adding redirector regex: 
> m'/(?:index.php)?\?.*(?<=[?&])URL=(.*?)(?:$|[&#])'i
> [16694] dbg: config: adding redirector regex: 
> m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/url\?.*?(?<=[?&])q=(.
> *?)(?:$|[&#])'i
> [16694] dbg: config: adding redirector regex: 
> m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/search\?.*?(?<=[?&])q
> =[^&]*?(?<=%20|..[=+\s])site:(.*?)(?:$|%20|[\s+&#])'i
> [16694] dbg: config: adding redirector regex: 
> m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/search\?.*?(?<=[?&])q
> =[^&]*?(?<=%20|..[=+\s])(?:"|%22)(.*?)(?:$|%22|["\s+&#])'i
> [16694] dbg: config: adding redirector regex: 
> m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/translate\?.*?(?<=[?&
> ])u=(.*?)(?:$|[&#])'i
> [16694] dbg: plugin: fixed relative path: 
> /etc/mail/spamassassin/FuzzyOcr.pm
> [16694] dbg: plugin: loading FuzzyOcr from 
> /etc/mail/spamassassin/FuzzyOcr.pm
> [16694] dbg: plugin: registered FuzzyOcr=HASH(0x9600a4c)
> [16694] dbg: plugin: FuzzyOcr=HASH(0x9600a4c) implements 'parse_config'
> [16694] dbg: FuzzyOcr: Option verbose = 1
> [16694] dbg: FuzzyOcr: Option logfile = /var/spool/amavis/FuzzyOcr.log
> [16694] dbg: FuzzyOcr: Option global_wordlist = 
> /etc/mail/spamassassin/FuzzyOcr.words
> [16694] dbg: FuzzyOcr: Found scan: $gocr -i -d 2 -l 100 $pfile
> [16694] dbg: FuzzyOcr: Found scan: $ocrad -s5 $pfile
> [16694] dbg: FuzzyOcr: Found scan: $ocrad -s5 -i $pfile
> [16694] dbg: FuzzyOcr: Score{wrongctype} = 0
> [16694] dbg: FuzzyOcr: Score{autodisable} = 50
> [16694] dbg: FuzzyOcr: Option counts_required = 2
> [16694] dbg: plugin: 
> Mail::SpamAssassin::Plugin::ReplaceTags=HASH(0x93439ec) 
> implements 'finish_parsing_end'
> [16694] dbg: plugin: FuzzyOcr=HASH(0x9600a4c) implements 
> 'finish_parsing_end'
> [16694] dbg: replacetags: replacing tags
> [16694] dbg: replacetags: done replacing tags
> [16694] dbg: FuzzyOcr: Using gifsicle => /usr/bin/gifsicle
> [16694] dbg: FuzzyOcr: Using giffix => /usr/bin/giffix
> [16694] dbg: FuzzyOcr: Using giftext => /usr/bin/giftext
> [16694] dbg: FuzzyOcr: Using gifinter => /usr/bin/gifinter
> [16694] dbg: FuzzyOcr: Using giftopnm => /usr/bin/giftopnm
> [16694] dbg: FuzzyOcr: Using jpegtopnm => /usr/bin/jpegtopnm
> [16694] dbg: FuzzyOcr: Using pngtopnm => /usr/bin/pngtopnm
> [16694] dbg: FuzzyOcr: Using bmptopnm => /usr/bin/bmptopnm
> [16694] dbg: FuzzyOcr: Using tifftopnm => /usr/bin/tifftopnm
> [16694] dbg: FuzzyOcr: Using ppmhist => /usr/bin/ppmhist
> [16694] dbg: FuzzyOcr: Using pamfile => /usr/bin/pamfile
> [16694] dbg: FuzzyOcr: Using gocr => /usr/bin/gocr
> [16694] dbg: FuzzyOcr: Using ocrad => /usr/bin/ocrad
> [16694] dbg: FuzzyOcr: Loaded <49> words from 
> "/etc/mail/spamassassin/FuzzyOcr.words"
> [16694] dbg: FuzzyOcr: Using scan: $gocr -i -d 2 -l 100 $pfile
> [16694] dbg: FuzzyOcr: Using scan: $ocrad -s5 $pfile
> [16694] dbg: FuzzyOcr: Using scan: $ocrad -s5 -i $pfile
> [16694] dbg: bayes: tie-ing to DB file R/O /root/.spamassassin/bayes_toks
> [16694] dbg: bayes: tie-ing to DB file R/O /root/.spamassassin/bayes_seen
> [16694] dbg: bayes: found bayes db version 3
> [16694] dbg: bayes: DB journal sync: last sync: 1164466703
> [16694] dbg: config: score set 2 chosen.
> [16694] dbg: message: ---- MIME PARSER START ----
> [16694] dbg: message: main message type: text/plain
> [16694] dbg: message: parsing normal part
> [16694] dbg: message: added part, type: text/plain
> [16694] dbg: message: ---- MIME PARSER END ----
> [16694] dbg: dns: is DNS available? 0
> [16694] dbg: metadata: X-Spam-Relays-Trusted: 
> [16694] dbg: metadata: X-Spam-Relays-Untrusted: 
> [16694] dbg: metadata: X-Spam-Relays-Internal: 
> [16694] dbg: metadata: X-Spam-Relays-External: 
> [16694] dbg: message: no encoding detected
> [16694] dbg: plugin: 
> Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c) implements 
> 'parsed_metadata'
> [16694] dbg: rules: local tests only, ignoring RBL eval
> [16694] dbg: check: running tests for priority: 0
> [16694] dbg: rules: running header regexp tests; score so far=0
> [16694] dbg: rules: ran header rule __HAS_MSGID ======> got hit: "<"
> [16694] dbg: rules: ran header rule __MSGID_OK_DIGITS ======> got 
> hit: "1164552269"
> [16694] dbg: rules: ran header rule __SANE_MSGID ======> got hit: 
> "<11...@lint_rules>
> [16694] dbg: rules: "
> [16694] dbg: rules: ran header rule __MSGID_OK_HOST ======> got 
> hit: "@lint_rules>"
> [16694] dbg: eval: all '*From' addrs: 
> ignore@compiling.spamassassin.taint.org
> [16694] dbg: eval: all '*To' addrs: 
> [16694] dbg: rules: ran eval rule NO_RELAYS ======> got hit
> [16694] dbg: rules: ran eval rule __UNUSABLE_MSGID ======> got hit
> [16694] dbg: rules: running body-text per-line regexp tests; 
> score so far=-0.001
> [16694] dbg: rules: ran body rule __NONEMPTY_BODY ======> got hit: "I"
> [16694] dbg: uri: running uri tests; score so far=-0.001
> [16694] dbg: bayes: DB journal sync: last sync: 1164466703
> [16694] dbg: bayes: corpus size: nspam = 3344, nham = 77141
> [16694] dbg: bayes: score = 0.505614028523142
> [16694] dbg: bayes: DB expiry: tokens in DB: 110804, Expiry max 
> size: 150000, Oldest atime: 1162231013, Newest atime: 1164287365, 
> Last expire: 1162733199, Current time: 1164552270
> [16694] dbg: bayes: DB journal sync: last sync: 1164466703
> [16694] dbg: bayes: untie-ing
> [16694] dbg: bayes: untie-ing db_toks
> [16694] dbg: bayes: untie-ing db_seen
> [16694] dbg: rules: ran eval rule BAYES_50 ======> got hit
> [16694] dbg: rules: running raw-body-text per-line regexp tests; 
> score so far=0
> [16694] dbg: rules: running full-text regexp tests; score so far=0
> [16694] dbg: plugin: 
> Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c) implements 
> 'check_tick'
> [16694] dbg: check: running tests for priority: 500
> [16694] dbg: plugin: 
> Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c) implements 
> 'check_post_dnsbl'
> [16694] dbg: rules: running meta tests; score so far=0
> [16694] info: rules: meta test DIGEST_MULTIPLE has undefined 
> dependency 'DCC_CHECK'
> [16694] info: rules: meta test MULTI_FORGED has dependency 
> 'FORGED_YAHOO_RCVD' with a zero score
> [16694] info: rules: meta test CONFIRMED_FORGED has dependency 
> 'FORGED_YAHOO_RCVD' with a zero score
> [16694] dbg: rules: running header regexp tests; score so far=0.122
> [16694] dbg: rules: running body-text per-line regexp tests; 
> score so far=0.122
> [16694] dbg: uri: running uri tests; score so far=0.122
> [16694] dbg: rules: running raw-body-text per-line regexp tests; 
> score so far=0.122
> [16694] dbg: rules: running full-text regexp tests; score so far=0.122
> [16694] dbg: check: running tests for priority: 900
> [16694] dbg: rules: running meta tests; score so far=0.122
> [16694] dbg: rules: running header regexp tests; score so far=0.122
> [16694] dbg: rules: running body-text per-line regexp tests; 
> score so far=0.122
> [16694] dbg: uri: running uri tests; score so far=0.122
> [16694] dbg: rules: running raw-body-text per-line regexp tests; 
> score so far=0.122
> [16694] dbg: rules: running full-text regexp tests; score so far=0.122
> [16694] dbg: check: running tests for priority: 1000
> [16694] dbg: rules: running meta tests; score so far=0.122
> [16694] dbg: rules: running header regexp tests; score so far=0.122
> [16694] dbg: rules: running body-text per-line regexp tests; 
> score so far=0.122
> [16694] dbg: uri: running uri tests; score so far=0.122
> [16694] dbg: rules: running raw-body-text per-line regexp tests; 
> score so far=0.122
> [16694] dbg: rules: running full-text regexp tests; score so far=0.122
> [16694] dbg: check: is spam? score=0.122 required=5
> [16694] dbg: check: 
> tests=BAYES_50,MISSING_SUBJECT,NO_RECEIVED,NO_RELAYS,TO_CC_NONE
> [16694] dbg: check: 
> subtests=__HAS_MSGID,__MSGID_OK_DIGITS,__MSGID_OK_HOST,__NONEMPTY_
> BODY,__SANE_MSGID,__UNUSABLE_MSGID
> 
>  
> Any ideas how to make local.cf parameters work?
> 
> 
> 
> Regards,
> Leon
> 


RE: optional score in local.cf is not working

Posted by Leon Kolchinsky <lk...@univ.haifa.ac.il>.

>
> I've upgraded to:
> amavisd-new-2.4.4-4
> spamassassin-3.1.7-3
> from:
> amavisd-new-20030616p9-3.6
> spamassassin-2.64-3.7
>
> These are optional scores in my local.cf:
>
> ## Optional Score
> score ROUND_THE_WORLD 0
> score SUBJ_ILLEGAL_CHARS 0
> score HEAD_ILLEGAL_CHARS 0
> score FORGED_HOTMAIL_RCVD2 0
> score FORGED_YAHOO_RCVD 0
> score SUBJ_ALL_CAPS 0
> score MISSING_SUBJECT 0
> score DNS_FROM_RFC_POST 0
> score DNS_FROM_RFC_ABUSE 0
>
> The problem is that it seems that I still get scorings for the above rules :(
>>3 quick guesses about the problem:
>>
>>1) make sure you restarted amavisd-new after making the edits to local.cf.
>>
>>2) run spamassassin --lint. This should run and exit quietly. Any
>>messages it prints are errors in your config file. SEVERAL things about
>>the syntax have changed from 2.6x to 3.1.x. See the UPGRADE file for
>>more details on some of the config changes. UPGRADE is in the tarball,
>>or can be found here:
>>
>>http://svn.apache.org/repos/asf/spamassassin/branches/3.1/UPGRADE
>>
>>3) run spamassassin --lint -D. See what SA thinks the "site rules dir"
>>is.. if that's not where your local.cf is, that's your problem.

1. AFAIK it is not necessary to restart amavisd-new, after a change in local.cf it is enough to restart spamd.

2. spamassassin --lint
Gives no output so it is OK I guess.

3. I've noticed that even whitelist_from_rcvd which worked fine with the old version is now not working, i.e. users in whitelist_from_rcvd now getting spam score enough to go to quarantine.

4. spamassassin --lint -D give the following output (as you can see below it reads local.cf: [16694] dbg: config: read file /etc/mail/spamassassin/local.cf):

[16694] dbg: logger: adding facilities: all
[16694] dbg: logger: logging level is DBG
[16694] dbg: generic: SpamAssassin version 3.1.7
[16694] dbg: config: score set 0 chosen.
[16694] dbg: util: running in taint mode? yes
[16694] dbg: util: taint mode: deleting unsafe environment variables, resetting PATH
[16694] dbg: util: PATH included '/sbin', keeping
[16694] dbg: util: PATH included '/usr/sbin', keeping
[16694] dbg: util: PATH included '/usr/local/sbin', keeping
[16694] dbg: util: PATH included '/root/bin', keeping
[16694] dbg: util: PATH included '/usr/local/bin', keeping
[16694] dbg: util: PATH included '/usr/bin', keeping
[16694] dbg: util: PATH included '/usr/X11R6/bin', keeping
[16694] dbg: util: PATH included '/bin', keeping
[16694] dbg: util: PATH included '/usr/games', keeping
[16694] dbg: util: PATH included '/opt/gnome/bin', keeping
[16694] dbg: util: PATH included '/opt/kde3/bin', keeping
[16694] dbg: util: PATH included '/usr/lib/java/jre/bin', keeping
[16694] dbg: util: final PATH set to: /sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin:/usr/games:/opt/gnome/bin:/opt/kde3/bin:/usr/lib/java/jre/bin
[16694] dbg: message: ---- MIME PARSER START ----
[16694] dbg: message: main message type: text/plain
[16694] dbg: message: parsing normal part
[16694] dbg: message: added part, type: text/plain
[16694] dbg: message: ---- MIME PARSER END ----
[16694] dbg: dns: is Net::DNS::Resolver available? yes
[16694] dbg: dns: Net::DNS version: 0.46
[16694] dbg: diag: perl platform: 5.008003 linux
[16694] dbg: diag: module installed: Digest::SHA1, version 2.07
[16694] dbg: diag: module not installed: Mail::SPF::Query ('require' failed)
[16694] dbg: diag: module not installed: IP::Country::Fast ('require' failed)
[16694] dbg: diag: module installed: Razor2::Client::Agent, version 2.82
[16694] dbg: diag: module not installed: Net::Ident ('require' failed)
[16694] dbg: diag: module not installed: IO::Socket::INET6 ('require' failed)
[16694] dbg: diag: module installed: IO::Socket::SSL, version 0.95
[16694] dbg: diag: module installed: Time::HiRes, version 1.52
[16694] dbg: diag: module installed: DBI, version 1.41
[16694] dbg: diag: module installed: Getopt::Long, version 2.34
[16694] dbg: diag: module installed: LWP::UserAgent, version 2.024
[16694] dbg: diag: module installed: HTTP::Date, version 1.46
[16694] dbg: diag: module installed: Archive::Tar, version 1.08
[16694] dbg: diag: module installed: IO::Zlib, version 1.04
[16694] dbg: diag: module installed: DB_File, version 1.808
[16694] dbg: diag: module installed: HTML::Parser, version 3.35
[16694] dbg: diag: module installed: MIME::Base64, version 2.21
[16694] dbg: diag: module installed: Net::DNS, version 0.46
[16694] dbg: diag: module installed: Net::SMTP, version 2.26
[16694] dbg: ignore: using a test message to lint rules
[16694] dbg: config: using "/etc/mail/spamassassin" for site rules pre files
[16694] dbg: config: read file /etc/mail/spamassassin/init.pre
[16694] dbg: config: read file /etc/mail/spamassassin/v310.pre
[16694] dbg: config: read file /etc/mail/spamassassin/v312.pre
[16694] dbg: config: using "/usr/share/spamassassin" for sys rules pre files
[16694] dbg: config: using "/usr/share/spamassassin" for default rules dir
[16694] dbg: config: read file /usr/share/spamassassin/10_misc.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_advance_fee.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_anti_ratware.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_body_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_compensate.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_dnsbl_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_drugs.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_fake_helo_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_head_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_html_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_meta_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_net_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_phrases.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_porn.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_ratware.cf
[16694] dbg: config: read file /usr/share/spamassassin/20_uri_tests.cf
[16694] dbg: config: read file /usr/share/spamassassin/23_bayes.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_accessdb.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_antivirus.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_body_tests_es.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_body_tests_pl.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_dcc.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_dkim.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_domainkeys.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_hashcash.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_pyzor.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_razor2.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_replace.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_spf.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_textcat.cf
[16694] dbg: config: read file /usr/share/spamassassin/25_uribl.cf
[16694] dbg: config: read file /usr/share/spamassassin/30_text_de.cf
[16694] dbg: config: read file /usr/share/spamassassin/30_text_fr.cf
[16694] dbg: config: read file /usr/share/spamassassin/30_text_it.cf
[16694] dbg: config: read file /usr/share/spamassassin/30_text_nl.cf
[16694] dbg: config: read file /usr/share/spamassassin/30_text_pl.cf
[16694] dbg: config: read file /usr/share/spamassassin/30_text_pt_br.cf
[16694] dbg: config: read file /usr/share/spamassassin/50_scores.cf
[16694] dbg: config: read file /usr/share/spamassassin/60_awl.cf
[16694] dbg: config: read file /usr/share/spamassassin/60_whitelist.cf
[16694] dbg: config: read file /usr/share/spamassassin/60_whitelist_dk.cf
[16694] dbg: config: read file /usr/share/spamassassin/60_whitelist_dkim.cf
[16694] dbg: config: read file /usr/share/spamassassin/60_whitelist_spf.cf
[16694] dbg: config: read file /usr/share/spamassassin/60_whitelist_subject.cf
[16694] dbg: config: using "/etc/mail/spamassassin" for site rules dir
[16694] dbg: config: read file /etc/mail/spamassassin/FuzzyOcr.cf
[16694] dbg: config: read file /etc/mail/spamassassin/local.cf
[16694] dbg: config: using "/root/.spamassassin/user_prefs" for user prefs file
[16694] dbg: config: read file /root/.spamassassin/user_prefs
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::URIDNSBL from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::Hashcash from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::Hashcash=HASH(0x928f360)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::SPF from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::SPF=HASH(0x92a5924)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::Pyzor from @INC
[16694] dbg: pyzor: local tests only, disabling Pyzor
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::Pyzor=HASH(0x92b8420)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::Razor2 from @INC
[16694] dbg: razor2: local tests only, skipping Razor
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::Razor2=HASH(0x92917fc)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::SpamCop from @INC
[16694] dbg: reporter: local tests only, disabling SpamCop
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::SpamCop=HASH(0x92938cc)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::AWL from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::AWL=HASH(0x9315964)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::AutoLearnThreshold from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::AutoLearnThreshold=HASH(0x9338db4)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::WhiteListSubject from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::WhiteListSubject=HASH(0x9329f1c)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::MIMEHeader from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::MIMEHeader=HASH(0x934bea4)
[16694] dbg: plugin: loading Mail::SpamAssassin::Plugin::ReplaceTags from @INC
[16694] dbg: plugin: registered Mail::SpamAssassin::Plugin::ReplaceTags=HASH(0x93439ec)
[16694] dbg: config: adding redirector regex: /^http:\/\/chkpt\.zdnet\.com\/chkpt\/\w+\/(.*)$/i
[16694] dbg: config: adding redirector regex: /^http:\/\/www(?:\d+)?\.nate\.com\/r\/\w+\/(.*)$/i
[16694] dbg: config: adding redirector regex: /^http:\/\/.+\.gov\/(?:.*\/)?externalLink\.jhtml\?.*url=(.*?)(?:&.*)?$/i
[16694] dbg: config: adding redirector regex: /^http:\/\/redir\.internet\.com\/.+?\/.+?\/(.*)$/i
[16694] dbg: config: adding redirector regex: /^http:\/\/(?:.*?\.)?adtech\.de\/.*(?:;|\|)link=(.*?)(?:;|$)/i
[16694] dbg: config: adding redirector regex: m'^http.*?/redirect\.php\?.*(?<=[?&])goto=(.*?)(?:$|[&#])'i
[16694] dbg: config: adding redirector regex: m'^https?:/*(?:[^/]+\.)?emf\d\.com/r\.cfm.*?&r=(.*)'i
[16694] dbg: config: adding redirector regex: m'/(?:index.php)?\?.*(?<=[?&])URL=(.*?)(?:$|[&#])'i
[16694] dbg: config: adding redirector regex: m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/url\?.*?(?<=[?&])q=(.*?)(?:$|[&#])'i
[16694] dbg: config: adding redirector regex: m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/search\?.*?(?<=[?&])q=[^&]*?(?<=%20|..[=+\s])site:(.*?)(?:$|%20|[\s+&#])'i
[16694] dbg: config: adding redirector regex: m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/search\?.*?(?<=[?&])q=[^&]*?(?<=%20|..[=+\s])(?:"|%22)(.*?)(?:$|%22|["\s+&#])'i
[16694] dbg: config: adding redirector regex: m'^http:/*(?:\w+\.)?google(?:\.\w{2,3}){1,2}/translate\?.*?(?<=[?&])u=(.*?)(?:$|[&#])'i
[16694] dbg: plugin: fixed relative path: /etc/mail/spamassassin/FuzzyOcr.pm
[16694] dbg: plugin: loading FuzzyOcr from /etc/mail/spamassassin/FuzzyOcr.pm
[16694] dbg: plugin: registered FuzzyOcr=HASH(0x9600a4c)
[16694] dbg: plugin: FuzzyOcr=HASH(0x9600a4c) implements 'parse_config'
[16694] dbg: FuzzyOcr: Option verbose = 1
[16694] dbg: FuzzyOcr: Option logfile = /var/spool/amavis/FuzzyOcr.log
[16694] dbg: FuzzyOcr: Option global_wordlist = /etc/mail/spamassassin/FuzzyOcr.words
[16694] dbg: FuzzyOcr: Found scan: $gocr -i -d 2 -l 100 $pfile
[16694] dbg: FuzzyOcr: Found scan: $ocrad -s5 $pfile
[16694] dbg: FuzzyOcr: Found scan: $ocrad -s5 -i $pfile
[16694] dbg: FuzzyOcr: Score{wrongctype} = 0
[16694] dbg: FuzzyOcr: Score{autodisable} = 50
[16694] dbg: FuzzyOcr: Option counts_required = 2
[16694] dbg: plugin: Mail::SpamAssassin::Plugin::ReplaceTags=HASH(0x93439ec) implements 'finish_parsing_end'
[16694] dbg: plugin: FuzzyOcr=HASH(0x9600a4c) implements 'finish_parsing_end'
[16694] dbg: replacetags: replacing tags
[16694] dbg: replacetags: done replacing tags
[16694] dbg: FuzzyOcr: Using gifsicle => /usr/bin/gifsicle
[16694] dbg: FuzzyOcr: Using giffix => /usr/bin/giffix
[16694] dbg: FuzzyOcr: Using giftext => /usr/bin/giftext
[16694] dbg: FuzzyOcr: Using gifinter => /usr/bin/gifinter
[16694] dbg: FuzzyOcr: Using giftopnm => /usr/bin/giftopnm
[16694] dbg: FuzzyOcr: Using jpegtopnm => /usr/bin/jpegtopnm
[16694] dbg: FuzzyOcr: Using pngtopnm => /usr/bin/pngtopnm
[16694] dbg: FuzzyOcr: Using bmptopnm => /usr/bin/bmptopnm
[16694] dbg: FuzzyOcr: Using tifftopnm => /usr/bin/tifftopnm
[16694] dbg: FuzzyOcr: Using ppmhist => /usr/bin/ppmhist
[16694] dbg: FuzzyOcr: Using pamfile => /usr/bin/pamfile
[16694] dbg: FuzzyOcr: Using gocr => /usr/bin/gocr
[16694] dbg: FuzzyOcr: Using ocrad => /usr/bin/ocrad
[16694] dbg: FuzzyOcr: Loaded <49> words from "/etc/mail/spamassassin/FuzzyOcr.words"
[16694] dbg: FuzzyOcr: Using scan: $gocr -i -d 2 -l 100 $pfile
[16694] dbg: FuzzyOcr: Using scan: $ocrad -s5 $pfile
[16694] dbg: FuzzyOcr: Using scan: $ocrad -s5 -i $pfile
[16694] dbg: bayes: tie-ing to DB file R/O /root/.spamassassin/bayes_toks
[16694] dbg: bayes: tie-ing to DB file R/O /root/.spamassassin/bayes_seen
[16694] dbg: bayes: found bayes db version 3
[16694] dbg: bayes: DB journal sync: last sync: 1164466703
[16694] dbg: config: score set 2 chosen.
[16694] dbg: message: ---- MIME PARSER START ----
[16694] dbg: message: main message type: text/plain
[16694] dbg: message: parsing normal part
[16694] dbg: message: added part, type: text/plain
[16694] dbg: message: ---- MIME PARSER END ----
[16694] dbg: dns: is DNS available? 0
[16694] dbg: metadata: X-Spam-Relays-Trusted: 
[16694] dbg: metadata: X-Spam-Relays-Untrusted: 
[16694] dbg: metadata: X-Spam-Relays-Internal: 
[16694] dbg: metadata: X-Spam-Relays-External: 
[16694] dbg: message: no encoding detected
[16694] dbg: plugin: Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c) implements 'parsed_metadata'
[16694] dbg: rules: local tests only, ignoring RBL eval
[16694] dbg: check: running tests for priority: 0
[16694] dbg: rules: running header regexp tests; score so far=0
[16694] dbg: rules: ran header rule __HAS_MSGID ======> got hit: "<"
[16694] dbg: rules: ran header rule __MSGID_OK_DIGITS ======> got hit: "1164552269"
[16694] dbg: rules: ran header rule __SANE_MSGID ======> got hit: "<11...@lint_rules>
[16694] dbg: rules: "
[16694] dbg: rules: ran header rule __MSGID_OK_HOST ======> got hit: "@lint_rules>"
[16694] dbg: eval: all '*From' addrs: ignore@compiling.spamassassin.taint.org
[16694] dbg: eval: all '*To' addrs: 
[16694] dbg: rules: ran eval rule NO_RELAYS ======> got hit
[16694] dbg: rules: ran eval rule __UNUSABLE_MSGID ======> got hit
[16694] dbg: rules: running body-text per-line regexp tests; score so far=-0.001
[16694] dbg: rules: ran body rule __NONEMPTY_BODY ======> got hit: "I"
[16694] dbg: uri: running uri tests; score so far=-0.001
[16694] dbg: bayes: DB journal sync: last sync: 1164466703
[16694] dbg: bayes: corpus size: nspam = 3344, nham = 77141
[16694] dbg: bayes: score = 0.505614028523142
[16694] dbg: bayes: DB expiry: tokens in DB: 110804, Expiry max size: 150000, Oldest atime: 1162231013, Newest atime: 1164287365, Last expire: 1162733199, Current time: 1164552270
[16694] dbg: bayes: DB journal sync: last sync: 1164466703
[16694] dbg: bayes: untie-ing
[16694] dbg: bayes: untie-ing db_toks
[16694] dbg: bayes: untie-ing db_seen
[16694] dbg: rules: ran eval rule BAYES_50 ======> got hit
[16694] dbg: rules: running raw-body-text per-line regexp tests; score so far=0
[16694] dbg: rules: running full-text regexp tests; score so far=0
[16694] dbg: plugin: Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c) implements 'check_tick'
[16694] dbg: check: running tests for priority: 500
[16694] dbg: plugin: Mail::SpamAssassin::Plugin::URIDNSBL=HASH(0x9247e4c) implements 'check_post_dnsbl'
[16694] dbg: rules: running meta tests; score so far=0
[16694] info: rules: meta test DIGEST_MULTIPLE has undefined dependency 'DCC_CHECK'
[16694] info: rules: meta test MULTI_FORGED has dependency 'FORGED_YAHOO_RCVD' with a zero score
[16694] info: rules: meta test CONFIRMED_FORGED has dependency 'FORGED_YAHOO_RCVD' with a zero score
[16694] dbg: rules: running header regexp tests; score so far=0.122
[16694] dbg: rules: running body-text per-line regexp tests; score so far=0.122
[16694] dbg: uri: running uri tests; score so far=0.122
[16694] dbg: rules: running raw-body-text per-line regexp tests; score so far=0.122
[16694] dbg: rules: running full-text regexp tests; score so far=0.122
[16694] dbg: check: running tests for priority: 900
[16694] dbg: rules: running meta tests; score so far=0.122
[16694] dbg: rules: running header regexp tests; score so far=0.122
[16694] dbg: rules: running body-text per-line regexp tests; score so far=0.122
[16694] dbg: uri: running uri tests; score so far=0.122
[16694] dbg: rules: running raw-body-text per-line regexp tests; score so far=0.122
[16694] dbg: rules: running full-text regexp tests; score so far=0.122
[16694] dbg: check: running tests for priority: 1000
[16694] dbg: rules: running meta tests; score so far=0.122
[16694] dbg: rules: running header regexp tests; score so far=0.122
[16694] dbg: rules: running body-text per-line regexp tests; score so far=0.122
[16694] dbg: uri: running uri tests; score so far=0.122
[16694] dbg: rules: running raw-body-text per-line regexp tests; score so far=0.122
[16694] dbg: rules: running full-text regexp tests; score so far=0.122
[16694] dbg: check: is spam? score=0.122 required=5
[16694] dbg: check: tests=BAYES_50,MISSING_SUBJECT,NO_RECEIVED,NO_RELAYS,TO_CC_NONE
[16694] dbg: check: subtests=__HAS_MSGID,__MSGID_OK_DIGITS,__MSGID_OK_HOST,__NONEMPTY_BODY,__SANE_MSGID,__UNUSABLE_MSGID

 
Any ideas how to make local.cf parameters work?



Regards,
Leon


Re: optional score in local.cf is not working

Posted by Matt Kettler <mk...@verizon.net>.
Leon Kolchinsky wrote:
> Hello All,
>
> I've upgraded to:
> amavisd-new-2.4.4-4
> spamassassin-3.1.7-3
> from:
> amavisd-new-20030616p9-3.6
> spamassassin-2.64-3.7
>
> These are optional scores in my local.cf:
>
> ## Optional Score
> score ROUND_THE_WORLD 0
> score SUBJ_ILLEGAL_CHARS 0
> score HEAD_ILLEGAL_CHARS 0
> score FORGED_HOTMAIL_RCVD2 0
> score FORGED_YAHOO_RCVD 0
> score SUBJ_ALL_CAPS 0
> score MISSING_SUBJECT 0
> score DNS_FROM_RFC_POST 0
> score DNS_FROM_RFC_ABUSE 0
>
> The problem is that it seems that I still get scorings for the above rules :(
3 quick guesses about the problem:

1) make sure you restarted amavisd-new after making the edits to local.cf.

2) run spamassassin --lint. This should run and exit quietly. Any
messages it prints are errors in your config file. SEVERAL things about
the syntax have changed from 2.6x to 3.1.x. See the UPGRADE file for
more details on some of the config changes. UPGRADE is in the tarball,
or can be found here:

http://svn.apache.org/repos/asf/spamassassin/branches/3.1/UPGRADE

3) run spamassassin --lint -D. See what SA thinks the "site rules dir"
is.. if that's not where your local.cf is, that's your problem.