Bug#702116: exim4-daemon-heavy: LDAP for SMTP auth not working

Andreas Metzler ametzler at downhill.at.eu.org
Wed Mar 6 18:33:01 UTC 2013


On 2013-03-02 Paul Muster <paul at muster.dyndns.info> wrote:
[...]
> The second box on
> http://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_plaintext_authenticator.html#SECID173
> shows an example which I customized for my environment:

> --> /etc/exim4/conf.d/auth/40_LDAP-auth
> plain_server:
>   driver = plaintext
>   public_name = PLAIN
>   server_prompts = Username:: : Password::
>   server_condition = ${if and{{ \
>     !eq{}{$auth2} }{ \
>     ldapauth{\
>       user="uid=${quote_ldap_dn:$auth2},ou=Users,dc=BASE" \
>       pass=${quote:$auth3} \
>       ldap://ldap/} }} }
[...]

Hello,

your version is a mixture of LOGIN and PLAIN, it identifies itself as 
as PLAIN and uses auth2/auth3 but specifies nonempty server_prompts.

I think something like these would work:

plain_server_ldap:
  driver = plaintext
  public_name = PLAIN
  server_prompts = :
  server_condition = ${if and{{ \
    !eq{}{$auth2} }{ \
    ldapauth{\
      user="uid=${quote_ldap_dn:$auth2},ou=Users,dc=BASE" \
      pass=${quote:$auth3} \
      ldap://ldap/} }} }
  server_set_id = $auth2

login_server_ldap:
  driver = plaintext
  public_name = LOGIN
  server_prompts = Username:: : Password::
  server_condition = ${if and{{ \
    !eq{}{$auth1} }{ \
    ldapauth{\
      user="uid=${quote_ldap_dn:$auth1},ou=Users,dc=BASE" \
      pass=${quote:$auth2} \
      ldap://ldap/} }} }
  server_set_id = $auth1

cu andreas
-- 
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'



More information about the Pkg-exim4-maintainers mailing list