Re: [exim] Using saslauthd with exim.

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Phil Pennock
Ημερομηνία:  
Προς: Alexander Kitaev
Υ/ο: exim-users
Αντικείμενο: Re: [exim] Using saslauthd with exim.
On 2011-02-25 at 20:33 +0100, Alexander Kitaev wrote:
> server_condition = ${if saslauthd{{$auth2}{$auth3}}{0}{1}}


That looks very wrong: you appear to be inverting success/failure: "if
authentication with saslauthd succeeds, then 0 (fail authentication)
else 1 (succeed authentication)".

> However, I'd like saslauthd to be called as:
>
> [user=name] [service=exim] [realm=domain.com] [mech=sasldb]...


http://www.exim.org/exim-html-current/doc/html/spec_html/ch11.html#SECTexpcond

The saslauthd condition takes up to 4 sub-parameters, the last two are
optional:

saslauthd {{<user>}{<password>}{<service>}{<realm>}}


  server_condition = ${if saslauthd{\
    {${local_part:$auth2}}\
    {$auth3}\
    {exim}\
    {${domain:$auth2}}}}


-Phil