[exim] LDAP router section

Top Page
Delete this message
Reply to this message
Author: Stanczak Slawomir
Date:  
To: exim-users
Subject: [exim] LDAP router section
Hi,

I have to set LDAP router section in my exim4.conf

I read:

http://exim.org/exim-html-current/doc/html/spec_html/ch15.html#id560622

I very sorry but I don't understand it at all.

My exaple LDAP account:

dn: uid=test,ou=People,dc=ams,dc=szn,dc=pl
uid: test
cn: test
objectClass: account
objectClass: posixAccount
objectClass: top
objectClass: shadowAccount
userPassword: {MD5}xxxxxxxxxxxxxxxxxxxxxxxxxx
shadowLastChange: 14844
loginShell: /bin/bash
uidNumber: 2205
gidNumber: 1001
homeDirectory: /home/prac/Adm/test
gecos: Test, BPE Rek/AMS


ara:~# ldapsearch -x -b dc=ams,dc=szn,dc=pl '(uid=test)'
# extended LDIF
#
# LDAPv3
# base <dc=ams,dc=szn,dc=pl> with scope subtree
# filter: (uid=test)
# requesting: ALL
#

# test, people, ams.szn.pl
dn: uid=test,ou=people,dc=ams,dc=szn,dc=pl
uid: test
cn: test
objectClass: account
objectClass: posixAccount
objectClass: top
objectClass: shadowAccount
loginShell: /bin/bash
uidNumber: 2205
gidNumber: 1001
homeDirectory: /home/prac/Adm/test
gecos: Test, BPE Rek/AMS

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1

-----------

My example LDAP router section:

ldap_user:
debug_print = "R: ldap_user for $local_part@$domain"
driver = accept
domains = +local_domains
local_parts = ${extract{uid}{${lookup ldap{ldap://212.14.2.145:389/ou=People,dc=ams,dc=szn,dc=pl}fail}}}
transport = local_delivery
cannot_route_message = Unknown user

How have I to set local_parts line?

Regards

Slawomir Stanczak