On Wed, Aug 18, 2004 at 09:40:48PM +0200, Jan Theofel wrote:
> 1. How can I find out if a rule like this exists in spamassassin or SARE?

grep X-Message /whereever/you/have/the/rules/*.cf

It's in 3.0 BTW:

header X_MESSAGE_INFO            exists:X-Message-Info
score X_MESSAGE_INFO 3.600 4.187 4.162 4.244

Good rule. :)

> 2. I tried adding these lines to my local.cf:
> 
> header          ETES_X_MESSAGE_INFO X-Message-Info =~ /.*/
> score           ETES_X_MESSAGE_INFO 0.01
> 
> The Problem is, that this matches every message, even these which don't have
> and X-Message-Info header line at all. How to fix this rule? (The content of
> the X-Message-Info line is unimportant.)

Right.  You're trying to match /.*/ which will match anything,
even nothing.  In RE form, you'd want /./ which would match any single
character, but the correct way to do it in SpamAssassin is use "exists:"
since you don't actually care if there's any data in the header, you
just care if the header exists.

-- 
Randomly Generated Tagline:
"Yogi Bear went to hell in a pic-a-nic basket, NOT a handbasket..."
                      - Theo

Attachment: pgpawvnTnEk2Y.pgp
Description: PGP signature

Reply via email to