On Tue, 22 Jun 2010 10:06:55 +0100
Dave Evans wrote:
> On Tue, Jun 22, 2010 at 09:50:40AM +0300, Nikita Koshikov wrote:
> > > > This is working on smtp-time MAIL FROM stage as I needed, but headers doesn't touched by it.
> > > > Adding one more rule without S flag didn't help and body headers From, Sender, etc list unrewritten data.
> > > >
> > > > What's wrong and how can I fix this ?
> > >
> > > \N^(.*)\*admin(.*)?$\N $1$2 Sh
> > >
> > The problem that - it doesn't work. I have tried various combination of flags, RhFfs etc, but headers in body never touched by rewrite.
>
> What do you mean by "headers in body"? Exim address rewriting will only consider
> the envelope addresses and the message headers, which end at the first blank line.
>
> If you're looking for a way to rewrite email addresses which appear in the
> body - even if they're rather header-like, such as this (which is part of this
> message's body):
>
> -----Original Message-----
> From: Dave Evans <exim-users-20081202@???>
> To: exim-users@???
>
> On some day or other, somebody wrote:
> .....
>
> then Exim rewrite rules ain't the way to do it. Modifying bodies is best
> avoided - see http://wiki.exim.org/FAQ/Modifying_message_bodies for some
> discussion of this.
>
I meant message headers,(all data after DATA command and before first blank line), sorry for misspelling.
Together:
Envelope addresses are rewritten ok
Message headers - don't.