Bonsoir,
merci pour ta réponse ça fais plaisir 
Le pb c'est que dans le cahier des charges de mon projet en cours, je dois utiliser LDAP, je refais un topo sur ma config :
res_ldap.conf
Code:
;
; Configuration file for res_config_ldap
;
; Realtime configuration
; ----------------------
; In order to use this module, you start
; in extconfig.conf with a configuration like this:
;
; sipusers = ldap,"dc=myDomain,dc=myDomainExt",sip
; sippeers = ldap,"dc=myDomain,dc=myDomainExt",sip
; extensions = ldap,"dc=myDomain,dc=myDomainExt",extensions
; sip.conf = ldap,"dc=myDomain,dc=myDomainExt",config
;
; In the case of LDAP the last keyword in each line above specifies
; a section in this file.
; TLS support
; -----------
; Note that you can configure an ldaps: url here to get TLS support.
; Detailed configuration of certificates and supported CAs is done in your
; ldap.conf file for OpenLDAP clients on your system.
; This requires that you have OpenLDAP libraries compiled with TLS support
; *********************************************************************************
; NOTE: res_ldap.conf should be chmod 600 because it contains the plain-text LDAP
; password to an account with WRITE access to the asterisk configuration.
; *********************************************************************************
[_general]
;
; Specify one of either host and port OR url. URL is preferred, as you can
; use more options.
host=192.168.1.15 ; LDAP host
port=389
;url=ldap://192.168.1.14:389
protocol=3 ; Version of the LDAP protocol to use; default is 3.
basedn=dc=voip,dc=local ; Base DN
user=cn=Administrateur,dc=voip,dc=local ; Bind DN
pass=Alonso95 ; Bind password
[sip]
name = cn ; We use the "cn" as the default value for name on the line above
; because objectClass=AsteriskSIPUser does not include a uid as an allowed field
; If your entry combines other objectClasses and uid is available, you may
; prefer to change the line to be name = uid, especially if your LDAP entries
; contain spaces in the cn field.
; You may also find it appropriate to use something completely different.
; This is possible by changing the line above to name = AstAccountName (or whatever you
; prefer).
;
callerid = telephoneNumber
context = info
host = ipPhone
secret = userPassword
sip.conf
Code:
[general]
rtcachefriends=yes
callevents=yes
realm=192.168.1.15
extconfig.conf
Code:
[settings]
sipusers = ldap,"dc=voip,dc=local",sip
sippeers = ldap,"dc=voip,dc=local",sip
-Mon LDAP est un active directory donc windows, comme vous avez pu remarqué j'ai mis les attributs en fonction de AD dans mon res_ldap.conf pour communiquer avec Asterisk.
-J'ai crée un utilisateur toto dans mon AD avec comme numéro ip = 2000@192.168.1.14 ( adresse de mon asterisk)
- Je rentre donc cette adresse sur mon softphone mais il n'arrive pas à s'enregistrer + mon mot de passe du user LDAP , sur mon Wireshark je vois que il y a comme paquet ( Register to 192.168.1.15(@LDAP) - 100 Trying - 401 Unauthorized)
un extrait de mes logs
Code:
[May 8 23:17:53] ERROR[2845] netsock2.c: getaddrinfo("2000@192.168.1.14", "(null)", ...): Name or service not known
[May 8 23:17:53] WARNING[2845] acl.c: Unable to lookup '2000@192.168.1.14'
[May 8 23:17:53] NOTICE[2845] chan_sip.c: Registration from '"2000"<sip:2000@192.168.1.14>' failed for '192.168.1.11:22441' - No matching peer found
[May 8 23:17:53] WARNING[2845] chan_sip.c: Retransmission timeout reached on transmission 1ef0caba0beb33f55bf69c8c61158baa@192.168.1.14 for seqno 105 (Critical Request) -- See doc/sip-retransmit.txt.
Packet timed out after 100285ms with no response
[May 8 23:22:08] NOTICE[2668] cdr.c: CDR simple logging enabled.
[May 8 23:22:09] NOTICE[2668] loader.c: 211 modules will be loaded.
[May 8 23:22:14] NOTICE[2668] res_odbc.c: res_odbc loaded.
[May 8 23:22:14] NOTICE[2668] res_crypto.c: Key 'n' needs passcode.
[May 8 23:22:14] NOTICE[2668] res_crypto.c: Add the '-i' flag to the asterisk command line if you want to automatically initialize passcodes at launch.
[May 8 23:22:14] NOTICE[2668] res_crypto.c: Please run the command 'keys init' to enter the passcodes for the keys
[May 8 23:22:14] NOTICE[2668] res_smdi.c: No SMDI interfaces are available to listen on, not starting SMDI listener.
[May 8 23:22:14] WARNING[2668] loader.c: Error loading module 'res_pktccops': /usr/lib/asterisk/modules/res_pktccops.so: cannot open shared object file: No such file or directory
[May 8 23:22:14] WARNING[2668] loader.c: Error loading module 'chan_mgcp.so': /usr/lib/asterisk/modules/chan_mgcp.so: undefined symbol: ast_pktccops_gate_alloc
[May 8 23:22:14] WARNING[2668] loader.c: Module 'chan_mgcp.so' could not be loaded.
[May 8 23:22:15] NOTICE[2668] config.c: Registered Config Engine ldap
[May 8 23:22:15] ERROR[2668] res_config_pgsql.c: PostgreSQL RealTime: Failed to connect database asterisk on 127.0.0.1:
[May 8 23:22:15] WARNING[2668] res_config_pgsql.c: PostgreSQL RealTime: Couldn't establish connection. Check debug.
[May 8 23:22:15] NOTICE[2668] config.c: Registered Config Engine pgsql
[May 8 23:22:15] NOTICE[2668] config.c: Registered Config Engine curl
[May 8 23:22:15] NOTICE[2668] config.c: Registered Config Engine odbc
[May 8 23:22:15] WARNING[2668] chan_dahdi.c: Detected alarm on channel 4: Red Alarm
[May 8 23:22:15] WARNING[2668] chan_dahdi.c: Ignoring any changes to 'userbase' (on reload) at line 23.
[May 8 23:22:15] WARNING[2668] chan_dahdi.c: Ignoring any changes to 'vmsecret' (on reload) at line 31.
[May 8 23:22:15] WARNING[2668] chan_dahdi.c: Ignoring any changes to 'hassip' (on reload) at line 35.
[May 8 23:22:15] WARNING[2668] chan_dahdi.c: Ignoring any changes to 'hasiax' (on reload) at line 39.
[May 8 23:22:15] WARNING[2668] chan_dahdi.c: Ignoring any changes to 'hasmanager' (on reload) at line 47.
[May 8 23:22:16] NOTICE[2668] chan_skinny.c: Configuring skinny from skinny.conf
[May 8 23:22:16] ERROR[2668] chan_gtalk.c: connection referenced not found!
[May 8 23:22:16] WARNING[2668] cel_pgsql.c: CEL pgsql config file missing global section.
[May 8 23:22:16] NOTICE[2668] cel_tds.c: cel_tds has no global category, nothing to configure.
[May 8 23:22:16] WARNING[2668] cel_tds.c: cel_tds module had config problems; declining load
[May 8 23:22:16] WARNING[2668] pbx.c: Unable to register extension '2000', priority 1 in 'internal', already in use
[May 8 23:22:17] NOTICE[2668] pbx_ael.c: Starting AEL load process.
[May 8 23:22:17] NOTICE[2668] pbx_ael.c: AEL load process: parsed config file name '/etc/asterisk/extensions.ael'.
[May 8 23:22:17] NOTICE[2668] pbx_ael.c: AEL load process: checked config file name '/etc/asterisk/extensions.ael'.
[May 8 23:22:17] NOTICE[2668] pbx_ael.c: AEL load process: compiled config file name '/etc/asterisk/extensions.ael'.
[May 8 23:22:17] NOTICE[2668] pbx_ael.c: AEL load process: merged config file name '/etc/asterisk/extensions.ael'.
[May 8 23:22:17] NOTICE[2668] pbx_ael.c: AEL load process: verified config file name '/etc/asterisk/extensions.ael'.
Je sens que je suis prêt du but pourtant ça coince
Merci de votre aide!