Author: Dave C. Date: To: exim-users Subject: Re: [Exim] rewrite rule help
On Thu, 13 Jun 2002, Philip Hazel wrote:
> On Wed, 12 Jun 2002, Dave C. wrote:
>
> > ARGH.. I'm pulling my hair out over this.
>
> Don't do that. Just let time pass and it will fall out all by itself. :-)
Heh..
> > To: <Undisclosed Recipients:;>
>
> > I have been trying to get a rewrite rile, to convert that to something
>
> Rewrite rules only rewrite syntactically valid addresses (with the sole
> exception of the 'S' rule for SMTP arguments).
Er, I'm specifically using the 'S' flag. Shouldnt that be able to tackle
it?
Also, at one point, even though I had only specified 't' and NOT 'T',
the _envelope_ address got rewritten..
> > However, exim appears to be completely ignoring this rule. It leaves the
> > header untouched, and then the header_syntax check kicks in, and the 5xx
> > is issued..
>
> It won't find any valid addresses, so it won't try to rewrite them.
>
> The rewrite rules are intended for rewriting addresses, not for patching
> up malformed header lines. The rules operate per RFC 2822 address, not
> per header line. If Exim can't understand a header line, it just gives
> up.
>
> The only thing I can think of is to use a "condition" condition in your
> ACL to cut out the header_syntax_check when you see such a header. The
> only way to rewrite it would be in the local_scan() function. (Or,
> maybe, use headers remove and headers add in a system filter or a
> router.) However, local_scan() gets called after all the other checks,
> so you can't use it to patch up the header line before the syntax check.
>
>
>
>