[Exim] Re: Regex Address Rewriting at SMTP Time

Góra strony
Delete this message
Reply to this message
Autor: Bernard Massot
Data:  
Dla: exim-users
Temat: [Exim] Re: Regex Address Rewriting at SMTP Time
On Mon, Jun 02, 2003 at 05:21:10PM -0400, Jonathan Vanasco wrote:
>
> \N^(.*)@new.(.*)$\N $1@$2
>
> that works. (rewrite anything@??? => anything@anywhere )
>
> But why?
>
> what's with this framing?
>
> \N ____________$\N
>
> i couldn't find anything in the manual about it, except for that in an
> example at the end of section 30.

Quoted from chapter 11.1 of the doc :
«A portion of the string can specified as non-expandable by placing it
between two occurrences of \N. This is particularly useful for
protecting regular expressions, which often contain backslashes and
dollar signs. For example:

deny senders = \N^\d{8}[a-z]@some\.site\.example$\N

On encountering the first \N, the expander copies subsequent
characters without interpretation until it reaches the next \N or the
end of the string.»
--
Bernard Massot