This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Using an LDAP test server we will authenticate the user newton | |
# http://www.forumsys.com/tutorials/integration-how-to/ldap/online-ldap-test-server/ | |
# method 1: using ldapwhoami | |
# should return "Result: Success (0)" if authentication was successful | |
ldapwhoami -vvv -h ldap.forumsys.com -D "uid=newton,dc=example,dc=com" -x -w password | |
# method 2: using ldapsearch | |
# should return "result: 0 Success" if authentication was successful | |
ldapsearch -h ldap.forumsys.com -x -D uid=newton,dc=example,dc=com -w password -b "dc=example,dc=com" "(uid=newton)" |