Re: [exim] Decide what router to use according to the from f…

Top Page
Delete this message
Reply to this message
Author: Todd Lyons
Date:  
To: rblue, exim-users
Subject: Re: [exim] Decide what router to use according to the from field
Bringing this back on list.

On Tue, Jul 22, 2014 at 4:41 PM, rblue <rblue117@???> wrote:
> Hi,
>
> After a few tests, it looks like the variable isn't being used properly in
> the router because the data acl runs only after the router is decided - is
> that right? If so, is there any way to tell exim to choose the router only
> after the acl_smtp_data acl, which is where I can look up the $h_From
> variable?


I've been pushing you in the general direction. Now I'm going to hold
your hand.

>> Now, having said that, *WHEN* is this being called? Is this part of
>> the router process for delivery (i.e. at the end of the DATA phase)?
>> Or is the part of the router processing during address verification,
>> typically in the MAIL and RCPT acl's. It appears to be during the


In a somewhat standard configuration, the routers are processed 3 times:
1) Once during the acl_smtp_mail when it's processing verify=sender.
It passes the MAIL FROM (envelope sender) address through the routers
attempting to verify if it's a valid sender.
2) Once during the acl_smtp_rcpt when it's processing
verify=recipient. It passes *all* RCPT TO (envelope recipients)
addresses through the routers, attempting to verify if they are emails
it should be accepting (i.e. local domains, or from designated hosts
that you forward any received emails...if you are a smarthost).
3) After the email has been accepted (i.e. after the data phase), when
Exim is actually trying to deliver the message.

Conditions are just for *verification*. So if you don't want your
particular special router to do anything during the verification
phases, and only be processed during the actual delivery of the email
(i.e. after the data phase, when there is actually message headers
available to inspect), then add to your router:

verify = false

Make sure that there is a router that will accept the emails that this
particular router normally accepts (because if there is not, then the
email address won't pass verification during the rcpt acl, and your
exim will reject it).

...Todd
--
The total budget at all receivers for solving senders' problems is $0.
If you want them to accept your mail and manage it the way you want,
send it the way the spec says to. --John Levine