On Mon, Jun 21, 2010 at 7:38 AM, Nikita Koshikov <[email protected]> wrote:
> Hello exim experts,
>
> I need exim to rewrite addresses like: <u...@domain*admin> to the form 
> <u...@domain>.
>
> Here is the rule I made for this:
>
> \N^(.*)\*admin(.*)?$\N          $1$2 S
>
> 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 ?

See chapter 31 on rewriting in the doc at
http://www.exim.org/exim-html-current/doc/html/spec_html/ch31.html.
Specifically 31.7, 31.8, and 31.9, which deals with rewriting flags.
I suspect that in addition to "S" you'll want "h" for "rewrite all
headers".  These flags all go on the same rule-line, so it would look
something like this (I think, I didn't actually test this):

\N^(.*)\*admin(.*)?$\N          $1$2 Sh

FWIW I think that rule will match more than you expect it to if your
example is accurate.  But that's a different question which you didn't
ask yet...

--John

-- 
## List details at http://lists.exim.org/mailman/listinfo/exim-users 
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/

Reply via email to