LDAP Notes

From INIwiki
Jump to: navigation, search

Use the following command to test your LDAP search success:

ldapsearch -x -b "dc=inisec,dc=com" -D "cn=linuxldap,cn=users,dc=inisec,dc=com" \
-h 192.168.0.1 -p 389 -w ldapPasswd '(samaccountname=chad)' givenname sn mail


Remember when working with a 2003 ADS server connection you need to have the following two lines in you PHP code Add the following lines between the ldap_connect and the ldap_bind

ldap_set_option($ldapserver, LDAP_OPT_PROTOCOL_VERSION,3);
ldap_set_option($ldapserver, LDAP_OPT_REFERRALS,0);
Personal tools