Re: [exim] add_header when header already exists?

Top Page
Delete this message
Reply to this message
Author: Patrick von der Hagen
Date:  
To: exim-users
Subject: Re: [exim] add_header when header already exists?

Am Dienstag, den 30.10.2007, 22:07 +0000 schrieb Jethro R Binks:
[...]
> I'm not really expecting an answer, but the original poster might want to
> consider and maybe investigate what Exchange does with mail that has two
> Precedence headers: one from the original mail with a value other than
> "(bulk|junk|list)", plus one added by his Exim with one of those values.
> Which does Exchange believe? And does the order they appear in the
> headers matter?

Well, I don't feel good about adding a second header if a previous one,
perhaps even with the same value, already exists. I just don't like that
idea and I'll try to use conditions to prevent that.
Would have been nice if add_header had a flag to say "only if not
already present", but such a flag would in effect only be a shortcut to
a condition.


> (I note that RFC 2076 describes the use of Precedence header as
> "Non-standard, controversial, discouraged", although clearly it has
> extensive use via mailing list managers and the like. It also mentions
> the example value of "first-class", which I have never noticed).

Even if it is discouraged I don't really like the thought to use the
header for originally unintended side-effects.

> 1. make the assumption that no end client really uses a value of
> Precedence: that is other than bulk|junk|list, especially if the message
> is likely to be spam
>
> 2. rename any existing Precedence: header to be X-Precedence: or
> something, so at least its original value is preserved somewhere if the
> user really wants to see it

I'll try something like "if a Precedence: header exists: dont't touch
it, otherwise...", but that would make it impossible to realise wheter
the header has already been present or just added by me....


> 3. then let Exim add "Precedence: bulk" to allow Exchange to detect it.
>
> However, I see from:
>
> http://msexchangeteam.com/archive/2006/10/06/429115.aspx
>
> that Exchange 2007 will also not reply to a message with a header
> "X-Auto-Response-Suppress: OOF", so this may be a solution more palatable
> to the original poster. Shame - it would have been a good opportunity for

That's a great information, but a migration to Exchange 2007 is only
planned and so far I have to stick with Exchange 2003. Of course I'll
start adding that new header anyway. At least by extending it with
imftune and abusing that precedence-header, I'll be able to create a
solution that's almost as nice as my usual unix-setup... ;-)

--
CU,
Patrick.