Re: [exim] SRS forward

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Phil Pennock
Dátum:  
Címzett: John Horne
CC: exim-users
Tárgy: Re: [exim] SRS forward
On 2010-06-30 at 23:03 +0100, John Horne wrote:
> On Wed, 2010-06-30 at 14:18 -0700, Phil Pennock wrote:
> > On 2010-06-30 at 20:15 +0000, Christian Gregoire wrote:
> > > I've written an SRS forward router, which works fine but it always rewrites the sender address when I'd expect the rewrite to occur only if the incoming domain has an SPF record. Is that possible ?
> >
> > condition = ${if match{${lookup dnsdb{defer_never,txt=$sender_address_domain}}}{\N^v=spf1\s\N}}
> >
> We have found that occasionally multiple TXT records are present (for
> other things than SPF), and so tend to use a multiline regex. In the
> above example it would become:
>
>     ...{\N^(?m)v=spf1\s\N}}


Good catch, thanks. In addition ...

Prior to Exim 4.70, the TXT behaviour of dnsdb was problematic. 4.70
and 4.71 have behaviour geared towards DKIM.

As of Exim 4.72, this is now tunable. To get the interpretation defined
by RFC 4408, where individual text strings within an RR are concat'd
together, but keep newline termination between strings, you want:

${lookup dnsdb{>\n; txt=$sender_address_domain}}

See Item 4 in NEwStuff for 4.72.

Regards,
-Phil