ldapjs / node-ldapjs

LDAP Client and Server API for node.js
http://ldapjs.org
MIT License
1.61k stars 448 forks source link

Unable to use attributes: 'member;range=0-1499' in ldapjs search #951

Closed RajyashreeChat closed 1 year ago

RajyashreeChat commented 1 year ago

On upgrading ldapjs from version '2.3.3' to '3.0.2', 2.3.3 was able to get all values of the member attribute when we changed range minimum and maximum but with version 3.0.2 the client.search method started failing with error: "Error: attribute must be a valid string".

The code snippet of the options sent in the ldapjs client.search method has been attached below. let opts = { filter: cn=${cnValue}, scope: 'sub', attributes: [ 'member;range=0-1499'], timeLimit: 30 }

Is there some way we can send the range in attributes with the new ldapjs version or an alternate way to get all the data of member attribute at once (There are >2000 members for one object)?

jsumners commented 1 year ago

Duplicate of https://github.com/ldapjs/node-ldapjs/issues/895

RajyashreeChat commented 1 year ago

All the members were earlier being received by sending attributes in the form "member;range=0-1499", "member;range=1500-max' and so on. But with version "3.0.2", it is giving error. Is there some alternate way of getting member data for items having member>1500?

The problem is not resolved in the, issue tagged as duplicate.

jsumners commented 1 year ago

Regardless of resolution, this is a duplicate. It was closed due to lack of response. If you'd like to answer the question in that issue, feel free.