Questions tagged [ldapjs]

ldapjs is a pure JavaScript, from-scratch framework for implementing LDAP clients and servers in Node.js. It is intended for developers used to interacting with HTTP services in node and express.

ldapjs is a pure JavaScript, from-scratch framework for implementing LDAP clients and servers in Node.js. It is intended for developers used to interacting with HTTP services in node and express.

ldapjs implements most of the common operations in the LDAP v3 RFC(s), for both client and server. It is 100% wire-compatible with the LDAP protocol itself, and is interoperable with OpenLDAP and any other LDAPv3-compliant implementation.

120 questions
2
votes
1 answer

ldapjs connection times out after certain period of time

I have some issues regarding searchEntry in LDAP repository using LDAPjs. I am not very familiar with LDAP and because of that I might be missing something in the client implementation. The problem is that after some period of time LDAP there is no…
mr. Holiday
  • 1,780
  • 2
  • 19
  • 37
2
votes
2 answers

ldapjs create mock users and perform search

I'm creating an auth middleware app using LDAP and I'm having difficulty getting a search to work. I'm using Mocha for tests and I created a util.js to create a mock ldapjs server: let server = require('../mocks/ldapServer'); const ldap =…
Mark Robson
  • 1,298
  • 3
  • 15
  • 40
2
votes
0 answers

ldapjs not working with require

I'm having some trouble trying to use the 'ldapjs' In fact i'm stuck with the first instruction var ldap = require('ldapjs'); I get this error: Error: Module name "ldapjs" has not been loaded yet for context: _. Use require([]) …
1
vote
0 answers

TypeError: Cannot read properties of undefined with next-auth and ldapjs

I am trying to set up LDAP authentication in my application, but I have an error. When I click on the button, the form becomes empty, and nothing happens. I try again, and I have the following error : error My [...nextauth].js : const ldap =…
pmx
  • 11
  • 2
1
vote
1 answer

Why isn't my ldapjs code displaying error?

I'm very new to ldapjs, and am trying to write an authenticate(username, password) script. The steps I'm eventually trying to write are: bind to the admin, and I want to check for errors to see if the bind succeeded. search for the user in question…
NL3294
  • 984
  • 1
  • 10
  • 27
1
vote
1 answer

how to resolve ECONNRESET error in ldapjs?

I am working with LDAP JS. I am receiving ECONNRESET Error again and again, I also tried to browse it but no success. tried to add reconnect: true qualifier but no success. my code and error is as follows. const adConfiguration = { url:…
Asad Mehmood
  • 292
  • 2
  • 10
  • 20
1
vote
0 answers

Ldapjs is not returning error if not searched

I am trying to implement functionality where I can login with openldap. for that I am using ldapjs client API - http://ldapjs.org/ Below are my steps for login Get username and password from web form (ejs) find user using search API of ldapjs:…
Prasad Gavande
  • 213
  • 1
  • 4
  • 19
1
vote
0 answers

How does a trusting Active Directory domain controller validate credentials that exist only in the trusted domain?

Suppose an Active Directory domain controller smallapp.local which trusts another domain bigenterprise.local. There is a user Alice in the bigenterprise.local and she is able to login into smallapp.local with her password using LDAP bind. As…
sellonen
  • 181
  • 1
  • 5
1
vote
1 answer

ldapjs handling client.search response

I have the below code which is binding to an LDAP server and I want to return the user that I have added "ab" within the "interviewees" group (code taken from ldapjs client api page). I can see I am getting back a response from the server with the…
Johnny
  • 51
  • 4
1
vote
1 answer

LDAP Protocol and Connection in ReactJS

I am currently trying to build a proof of concept build of an LDAP connector in electron/Reactjs. My two main goals of building this connector are to be able to check if the user enters the correct credentials and LDAP address then they get a…
Austin S
  • 145
  • 1
  • 10
1
vote
1 answer

How can i set account options in active directory with ldapjs?

I have uses ldapjs module of nodejs to interact with my active directory. i can bind and add user into the active directory with these functions... ldapOptions = { url: //my ldap server ip, connectionTimeOut: 30000, reconnect:…
khodekazemi
  • 143
  • 10
1
vote
1 answer

Error: getaddrinfo EAI_AGAIN undefined (ldapjs)

So, i tried to deploy my Express.Js app to my vps, but I get some error that refined to Error: getaddrinfo EAI_AGAIN undefined. The weird part is, it is doing just fine if I run this app on my localhost. Any body knows how to resolve this…
1
vote
1 answer

How to modify memberOf field via ldapjs

When i try to pass memberOf field in JS dict during creation of a member or even to edit it after via const change = new Change({ operation: 'replace', modification: { [field]: value } }); return new Promise((resolve, reject) =>…
amshegarh
  • 13
  • 1
  • 3
1
vote
1 answer

Retry logic for connecting to backup ldap servers using ldapjs on nodejs

I have a primary ldap server url, say urlA and multiple backup server urls in a list. If the connection couldn't be made to the primary ldap server, the backup servers will be tried in the order they appear in the list. I am using ldapjs…
1
vote
1 answer

LdapJS server exop handling fails

I am using the LDAP server functionality of the Node.js module ldapjs version 1.0.2. I want to handle an LDAP 1.3.6.1.4.1.4203.1.11.1 extended operation (see RFC 3062 = LDAP Password Modify). My server is configured... const server =…
Manfred Steiner
  • 1,215
  • 2
  • 13
  • 27