Created
June 20, 2011 16:56
-
-
Save vpereira/1035988 to your computer and use it in GitHub Desktop.
simpleBind with gem https://github.com/jeremycx/node-LDAP/
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
var LDAPConnection = require("LDAP").Connection; | |
var LDAP = new LDAPConnection(); | |
if (LDAP.open("ldap://localhost", 3) < 0) { | |
throw new Error("Unable to connect to server"); | |
} | |
LDAP.simpleBind("cn=bigshot,dc=test,dc=com","opensesame",function(msgid,err){ | |
if(err) | |
console.log(err); | |
else | |
console.log(msgid); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment