[Asterisk-Users] LDAP direct authentication Problem

Chandan Mishra chandan.iitr at gmail.com
Wed Jan 18 06:20:33 MST 2006


Hi
I need to authenticate all the asterisk users from the LDAP server instead
of  from sip.conf.
If anybody already have done this then please guide.

I tried to integrate authenticate asterisk users from LDAP using the open
source project astirectory1.2.0.
After using the astirectory1.2.0 , now when the asterisk starts then it
registeres with the LDAP. Following logs shows it.

Jan 18 18:36:20 WARNING[26190]: res_config_ldap.c:641 parse_config: LDAP
RealTime Host: ldap://192.168.0.16
Jan 18 18:36:20 WARNING[26190]: res_config_ldap.c:642 parse_config: LDAP
RealTime User: synapse\dirsearch
Jan 18 18:36:20 WARNING[26190]: res_config_ldap.c:643 parse_config: LDAP
RealTime Base DN: dc=synapse,dc=com
Jan 18 18:36:20 WARNING[26190]: res_config_ldap.c:699 ldap_reconnect:
ldapuser:synapse\dirsearch ,ldappass12345678
Jan 18 18:36:20 WARNING[26190]: res_config_ldap.c:701 ldap_reconnect: LDAP
RealTime: Successfully connected to LDAP.
Jan 18 18:36:20 NOTICE[26190]: config.c:863 ast_config_engine_register:
Registered Config Engine
ldap

But when i try to connect the asterisk server using my Xlite client then the
first  asterisk  registers with the LDAP but the XLite user is not able to
authenticate. Following logs shows it.

Jan 18 18:47:38 WARNING[26197]: res_config_ldap.c:118 realtime_ldap: LDAP
RealTime: Retrieve LDAP: (&(objectClass=astsippeer)(astname=dirsearch))
Jan 18 18:47:38 WARNING[26197]: res_config_ldap.c:699 ldap_reconnect:
ldapuser:synapse\dirsearch ,ldappass12345678
Jan 18 18:47:38 WARNING[26197]: res_config_ldap.c:701 ldap_reconnect: LDAP
RealTime: Successfully connected to LDAP.
Jan 18 18:47:38 WARNING[26197]: res_config_ldap.c:129 realtime_ldap: LDAP
RealTime: Failed to query database. Check debug for more info.
Jan 18 18:47:38 WARNING[26197]: res_config_ldap.c:130 realtime_ldap: LDAP
RealTime: Query: (&(objectClass=astsippeer)(astname=dirsearch))
Jan 18 18:47:38 WARNING[26197]: res_config_ldap.c:132 realtime_ldap: LDAP
RealTime: Query Failed because: Operations error
Jan 18 18:47:38 NOTICE[26197]: chan_sip.c:10815 handle_request_register:
Registration from 'dirsearch <sip:dirsearch at 192.168.3.169>' failed for '
192.168.1.186' - Username/auth name mismatch

actually ldap_search_s(ldap, ldapbasedn, LDAP_SCOPE_ONELEVEL, query2, NULL,
0, &res) function is not execution successfully in the file
res_config_ldap.c.

I am not able to find the reason.


Chandan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060118/fa037d4b/attachment.htm


More information about the asterisk-users mailing list