vesse / node-ldapauth-fork

Simple node.js module to authenticate against an LDAP server
Other
127 stars 79 forks source link

Allow empty searchbases #43

Closed ansib closed 7 years ago

ansib commented 7 years ago

We have different organizations to get our users from the ldap. To get them from there, we need the option to give over a empty search base query, because our IBM Domino Server stores this informations in root of tree.

Would it be possible to exclude the assert.ok for the search base and set this as optional?

function LdapAuth(opts) { this.opts = opts; assert.ok(opts.url, 'LDAP server URL not defined (opts.url)'); assert.ok(opts.searchBase, 'Search base not defined (opts.searchBase)'); assert.ok(opts.searchFilter, 'Search filter not defined (opts.searchFilter)');

Thank you for the response.