You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Terry Miller <te...@millfam.org> on 2006/02/19 20:56:37 UTC

Exiscan + subject rewrite not working

I looked this up and can't see where I'm doing anything wrong, but the
subject is not being rewritten.

Some relevant data:

/etc/mail/spamassassin/local.cf

# How many hits before a message is considered spam.
required_score 3.0

# Change the subject of suspected spam
rewrite_header Subject *****SPAM*****

Changing the required score value shows up in the mail headers.

/etc/sysconfig/spamassassin

SPAMDOPTIONS="-d -m5 -H/var/spool/spamd "



I elimininated the -c option because of the following errors.


Feb 18 20:24:59 WBServer spamd[18388]: info: setuid to nobody succeeded
Feb 18 20:24:59 WBServer spamd[18388]: Creating default_prefs
[//.spamassassin/user_prefs]
Feb 18 20:24:59 WBServer spamd[18388]: Cannot write to
//.spamassassin/user_prefs: No such file or directory
Feb 18 20:24:59 WBServer spamd[18388]: Couldn't create readable
default_prefs for [//.spamassassin/user_prefs]


I'm not sure whether this has anything to do with the problem or not. I
don't see where the setuid to nobody comes from. I added the
/var/spool/spamd after the -H option and made spamd & the .spamassassin
subdirectory world writeable to see if this would eliminate the error but it
didn't.

>From exiscan.conf
acl_check_content:

  # Reject virus infested messages.
#  deny  message = This message contains malware ($malware_name)
#        malware = *

# Messages larger than 200k are accepted without spam scanning to reduce
spamd load accept condition = ${if >{$message_size}{150k}{true}}

  # Always add X-Spam-Score and X-Spam-Report headers, using SA system- wide
settings
  # (user "nobody"), no matter if over threshold or not.
  warn  message = X-Spam-Score: $spam_score ($spam_bar)
        spam = sa:true
  warn  message = X-Spam-Report: $spam_report
        spam = sa:true

  # Add X-Spam-Flag if spam is over system-wide threshold
  warn message = X-Spam-Flag: YES
       spam = sa

  # Reject spam messages with score over 10, using an extra condition.
  deny  message = This message scored $spam_score points. Congratulations!
        spam = sa:true
        condition = ${if >{$spam_score_int}{100}{1}{0}}

##
# Rewrite subject if email scored between 5 and 10.
##

# For the subject tag, we prepare a new subject header in the # ACL, then
swap it with the original Subject in the system filter.
        warn message =    X-Exiscan-SA-New-Subject: ***SPAM***$h_subject
		
	    	condition = ${if >{$spam_score_int}{50}{1}{0}}

  # finally accept all the rest
  accept
  

SpamAssassin version is 3.0.1, perl is 5.8.5, Exim is 4.4.3,
exiscan patch is patch revision 28.


RE: Exiscan + subject rewrite not working

Posted by Terry Miller <te...@millfam.org>.
You're right. 

You have to set a system filter, documentation is a little sparse on that. 

This link was helpful
http://ws.edu.isoc.org/workshops/2004/CEDIA/presentaciones/bc/correo/exim/Ex
imPrac.html

It works now, thanks for the reply.


-----Original Message-----
From: Tony Finch [mailto:dot@dotat.at] 
Sent: Sunday, February 19, 2006 3:40 PM
To: Terry Miller
Cc: users@spamassassin.apache.org
Subject: Re: Exiscan + subject rewrite not working


On Sun, 19 Feb 2006, Terry Miller wrote:

> I looked this up and can't see where I'm doing anything wrong, but the 
> subject is not being rewritten.

You should probably ask this question on the exim-users list. I suspect (but
I am not certain) that exiscan doesn't support the message rewrite parts of
SpamAssassin, and instead relies on Exim's own facilities for this..

Tony.
-- 
f.a.n.finch  <do...@dotat.at>  http://dotat.at/
BISCAY: WEST 5 OR 6 BECOMING VARIABLE 3 OR 4. SHOWERS AT FIRST. MODERATE OR
GOOD.



Re: Exiscan + subject rewrite not working

Posted by Tony Finch <do...@dotat.at>.
On Sun, 19 Feb 2006, Terry Miller wrote:

> I looked this up and can't see where I'm doing anything wrong, but the
> subject is not being rewritten.

You should probably ask this question on the exim-users list. I suspect
(but I am not certain) that exiscan doesn't support the message rewrite
parts of SpamAssassin, and instead relies on Exim's own facilities for
this..

Tony.
-- 
f.a.n.finch  <do...@dotat.at>  http://dotat.at/
BISCAY: WEST 5 OR 6 BECOMING VARIABLE 3 OR 4. SHOWERS AT FIRST. MODERATE OR
GOOD.