Re: [exim] PCRE virtual addresses

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Jim Trigg
Datum:  
To: exim-users
Betreff: Re: [exim] PCRE virtual addresses
On Wed, Feb 25, 2015 at 09:29:00AM +0000, Jasen Betts wrote:
> On 2015-02-25, Jim Trigg <jtrigg@???> wrote:
> > I'm switching from Postfix to Exim. The one facility that I use in
> > Postfix that I haven't figured out how to implement in Exim is PCRE
> > aliases. I include an example below. Any suggestions how to write a
> > router for this in Exim? Also, is there a different syntax I should
> > be using in the file?
>
> [...]
>
> > Munged example to elide actual domain names from my existing virtual.pcre:
> > /^(abuse|policyd|root)@(anydomain).tld$/    blaise+${2}-${1}@localhost
> > /^(host|list|post|web)master@(anydomain).tld$/    blaise+${2}-${1}@localhost
> > /^jtrigg([-+].+)@(anydomain).tld$/        blaise+${2}${1}@localhost
> > /^jtrigg@(anydomain).tld$/            blaise+${1}@localhost

>
> www.exim.org/exim-html-current/doc/.../ch-address_rewriting.html


(Originally accidentally sent privately.)

Sadly, there are two problems with this - first, while the idea of a
monolithic configuration file is fine in general, this is a specific
case where a separate file is indicated. Second, the innate address
rewriting is much more limited than PCRE. I'd have to do separate rules
for each of the service accounts, and for each domain in which jtrigg is
a valid recipient. (The server hosts multiple domains; for some my mail
username is jtrigg and for others it's blaise. Similarly, I have other
PCRE expressions for other users who are in more than one domain but not
all domains.)

Thanks,
Jim Trigg