You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Marcel Odendahl <mo...@nordsys.de> on 2004/08/09 15:14:16 UTC

add_header and spamd

Hi List,

I've some trouble with SpamAssassin 2.63.
I'm running a mail server on linux with sendmail 8.12.11.
SpamAssassin is integrated into sendmail with spamass-milter which
starts spamd.
Now I want to add some headers to the scanned mail with no luck.
I've added to the file /usr/share/spamassassin/10_misc.cf
the following lines.
add_header all Level _STARS(*)_
add_header all Hits _HITS_

I know this is the wrong place but it is still for testing.

Unfortunately these headers are not added when the mail is no spam.
They are only added when the mail is spam.
When I use spamassassin to test my configuration everything works as
expected. The headers are added wether the mail is spam or not.

I'm using the configuration which is delivered with the spamassassin
archive.

With best regards,

Marcel.


Re: add_header and spamd

Posted by Marcel Odendahl <mo...@nordsys.de>.
On Mon, 2004-08-09 at 15:31, Matt Kettler wrote:

Hi Matt,

> Did you remove the default add_header commands?
> 

no.

> It seems like you're getting the default behavior, which would happen if 
> you added those lines to the top of 10_misc.cf, and they got clobbered by 
> the defaults later on down the file.
> 
> I'd really suggest doing this with clear_header and a series of commands in 
> a .cf file in your /etc/mail/spamassasin directory. It's a lot easier to 
> remove if you screw up.
> 

Ok, I've tested it with a new config file.
This file I placed in the /etc/mail/spamassassin directory.
clear_headers
add_header all Level _STARS(*)_
add_header all Hits _HITS_

Afer a restart of spamd I only get the
X-Spam-Checker-Version
header, which is always added as mentioned in the docs.

Regards,

Marcel.


Re: add_header and spamd

Posted by Matt Kettler <mk...@comcast.net>.
At 03:14 PM 8/9/2004 +0200, Marcel Odendahl wrote:
>I've added to the file /usr/share/spamassassin/10_misc.cf
>the following lines.
>add_header all Level _STARS(*)_
>add_header all Hits _HITS_
>
>I know this is the wrong place but it is still for testing.
>
>Unfortunately these headers are not added when the mail is no spam.
>They are only added when the mail is spam.
>When I use spamassassin to test my configuration everything works as
>expected. The headers are added wether the mail is spam or not

Did you remove the default add_header commands?

It seems like you're getting the default behavior, which would happen if 
you added those lines to the top of 10_misc.cf, and they got clobbered by 
the defaults later on down the file.

I'd really suggest doing this with clear_header and a series of commands in 
a .cf file in your /etc/mail/spamassasin directory. It's a lot easier to 
remove if you screw up.

And as always, don't forget to --lint, and restart spamd after you're done 
editing.