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

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Todd Lyons
Data:  
Para: rblue
CC: exim-users
Assunto: Re: [exim] Decide what router to use according to the from field
On Thu, Jul 17, 2014 at 1:49 PM, rblue <rblue117@???> wrote:

> Thanks for these debugging options, they were really helpful. So the router
> isn't being used because the condition is failing as expected, and these are
> the debugging messages:
>
> checking "condition"
> expanding: NULL
>    result: NULL
> considering bool_lax: NULL
> expanding: $acl_m_use_ses
>    result:
> expanding: 1
>    result: 1


It appears to be set to "1". Make sure there are no trailing spaces
in the line which sets this variable.

> condition: eq{$acl_m_use_ses}{1}
>    result: false


Is there a space before or after that 1 in your test?

> expanding: yes
>    result: yes


That comes from the way an if statement is processed:

${if eq{expand this}{expand_this}
{yes is expanded}{no is expanded} }

So what you are seeing is the result of an expansion of "yes", and
below is an expansion of "no". Since neither of them actually have
any variables or expansion functions, it's just "yes" and "no".

> skipping: result is not used


It's saying "the condition was not true, so we're skipping the 'true' bracket".

> expanding: no
>    result: no
> expanding: ${if eq{$acl_m_use_ses}{1} {yes}{no}}
>    result: no


It's followed that up with "the condition was not true, so we're using
the 'false' bracket".

> I can't tell if $acl_m_use_ses is or not equal to 1. I assume it is due to
> these lines:
>
> expanding: $acl_m_use_ses
>    result:
> expanding: 1
>    result: 1


Yes.

> but I'm unsure why this is resulting as false:
>
> condition: eq{$acl_m_use_ses}{1}
>    result: false
> Any ideas?


Leading or trailing spaces most likely.

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
data phase, but I can't tell for sure since you snipped away anything
useful before or after 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