[Exim] stuck using LDAP to authenticate for SMTP AUTH plain

Pàgina inicial
Delete this message
Reply to this message
Autor: Chad Leigh, Pengar Enterprises, Inc & Shire.Net LLC
Data:  
A: exim-users@exim.org
CC: chad
Assumpte: [Exim] stuck using LDAP to authenticate for SMTP AUTH plain
Hi

I am trying to set up an AUTHP PLAIN SMTP AUTH server side authenticator.
I use LDAP to authenticate my users (no logins, mail only). I have my own
LDAP records set up and one of the attributes is emailAddress which is of
the form "user@???" I use the full email address as the username for
imap/pop and for authentication as that allows all sorts of virtual
domains. :-)

Anyway, using C034 in the config samples, and the nis example listed
therein, I came up with the following: it fails when I use it over exim
-bh as the ldap fails to find the info.

plain:
driver = plaintext
public_name = PLAIN
server_condition = ${if and {{!eq{$2}{}}{!eq{$3}{}} {crypteq{$3}{${lookup
ldap {user="cn=Manager,dc=me,dc=mytld" pass=mypasswd ldap://
myhost.me.mytld:389/emailAddress=$2,dc=me,dc=mytld?userpassword}{$value}fai
l}}}{1}{0}}
server_set_id = $2

the ldapsearch that works for this at the command line is (maybe I am
translating this to URL form incorrectly):

ldapsearch -D "cn=Manager,dc=me,dc=mytld" -w mypasswd -s sub -b
"dc=me,dc=mytld" "emailAddress=chad@???"
accountname=chad, domain=pengar.com, dc=me, dc=mytld
objectclass=emailaccount
accountname=chad
domain=pengar.com
emailaddress=chad@???
mailboxloc=/var/spool/mail/pengar.com/c/chad
accountactive=Y
virusscan=Y
spamfilter=Y
userpassword={md5}WuGr5FgWYmcHByKFzSQkRA==


Any hints appreciated.

Thanks
Chad

Pengar Enterprises, Inc. and Shire.Net LLC
Web and Macintosh Consulting -- full td>ice web hosting
Chad Leigh    
chad@???            chad@???