On Wednesday 14 February 2007 00:54, Matthew Wakeling wrote:
> I have been using exim for a very long time now. A year or so ago I
> upgraded from exim 3 to exim 4. I use spamassassin to add headers to the
> incoming emails, using the built-in exiscan system and a spamd server. I
> then use a .forward file to define what happens to my mail. Here is part
> of my forward file:
>
> if $message_headers contains "X-Spam_bar: +++++++++++" then
>          save $home/mail/mail/spam
>          finish
> endif
>
> if $message_headers contains "X-Spam_bar: +++++" then
>          save $home/mail/mail/guessedspam
>          finish
> endif

Use

if $h_X-Spam_bar: contains "++++++++++++" then

instead.

> Over the last few weeks, a few spam messages have started to be delivered
> to my inbox, even though they are marked as spam by spamassassin. These
> messages definitely have a header saying "X-Spam_bar: +++++++++++++" or
> longer, yet the rule in the .forward file redirecting the mail to my spam
> folder is not being obeyed. Only a few of the messages are affected. The
> majority of my incoming spam is still redirected to my spam folder.

What do the logs say? You can also test your filters with exim -bf, optionally 
with debugging on. See the man page or 
http://www.no.exim.org/exim-html-4.66/doc/html/spec_html/ch05.html for more 
details.

> Has anyone else had this problem? Is there a possibility of a race
> condition introduced in exim over the last couple of months? Does the
> exiscan always run before the .forward file is processed?

Exiscan runs from the ACLs during the message reception phase, before writing 
the message to the spool, and if it hasn't run, there would be no X-Spam_bar 
header field. Filters run from a router during the delivery phase, with the 
message on the spool.

-- 
Magnus Holmgren        [EMAIL PROTECTED]
                       (No Cc of list mail needed, thanks)

  "Exim is better at being younger, whereas sendmail is better for 
   Scrabble (50 point bonus for clearing your rack)" -- Dave Evans

Attachment: pgpdc7dZS137c.pgp
Description: PGP signature

-- 
## List details at http://www.exim.org/mailman/listinfo/exim-users 
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://www.exim.org/eximwiki/

Reply via email to