On Wed, Mar 28, 2012 at 9:40 AM, Mikel <mgilsanz@xxxxxxxxxxxxxx> wrote:
Thank you Steve
The matter is that, I have configurated ldap-aliases.cfbind_pw= password
server_host = 10.48.1.198
bind = yes
version = 3
bind_dn= cn=sogoprueba,cn=Users,dc=avalon,dc=com,dc=es
search_base = dc=Avalon,dc=com,dc=es
ldap_filter = *
result_attribute = mail
#special_result_filter = %u@%d
But if I run:
postmap -q mgilsanz@xxxxxxxxxxxxxx ldap:/etc/postfix/ldap-aliases.cf
or I don't get nothing....and I think that the problem about postfix is not able to find users.
If I query to ldap with ldapsearch:
ldapsearch -P3 -a never -x -H ldap://10.48.1.198 -D 'cn= sogoprueba,cn=Users,dc=avalon,dc=com,dc=es' -w password -b 'dc=Avalon,dc=com,dc=es' '(cn=*)' mail | grep mgilsanz the result is:
mail: mgilsanz@xxxxxxxxxxxxxx
I answer about the filter on ldap-aliases.cf of postfix
how about result_attribute = mail in ldap-aliases.cf because if I am be able to do ldapsearch
and find user mgilsanz How can I do the same query in ldap-aliases.cf to find users in my domain?
Any idea, I think that the problem is Ldap query but I don't know what is wron...
First, why the difference dc=Avalon,dc=com,dc=es and dc=avalon,dc=com,dc=es?
Also, ldap_filter should be query_filter and should have an _expression_ with attributes in it. Your ldapsearch command is more complex than your postfix ldap-aliases.cf. Can you please show the ldif of a single user?
Steve