Closed classmatewu closed 1 year ago
It is not "gibberish". It is escaped as per the spec (https://www.rfc-editor.org/rfc/rfc4514). What is the use case for the unescaped string?
It is not "gibberish". It is escaped as per the spec (https://www.rfc-editor.org/rfc/rfc4514). What is the use case for the unescaped string?
"\e7\a0\94\e5\8f\91\e4\ba\8c\e7\bb\84"-> "研发二组"
Please write actual explanations. Simply responding:
"\e7\a0\94\e5\8f\91\e4\ba\8c\e7\bb\84"-> "研发二组"
is not sufficient explanation of anything. It literally says nothing.
Please write actual explanations. Simply responding:
"\e7\a0\94\e5\8f\91\e4\ba\8c\e7\bb\84"-> "研发二组"
is not sufficient explanation of anything. It literally says nothing.
this is my demo
client.search(baseDN, {
filter: 'objectclass=organizationalUnit',
scope: 'one',
attributes: ['o', 'ou']
}, (err, res) => {
if (err) {
console.log(err);
} else {
res.on('searchEntry', (entry) => {
console.log('dn: ' + entry.dn.toString());
// "ou=\e7\a0\94\e5\8f\91\e4\ba\8c\e7\bb\84,o=test,dc=test,dc=com"
// expect: "ou=研发二组,o=test,dc=test,dc=com"
});
res.on('error', function (err) {
console.error('error: ' + err.message);
client.unbind();
});
res.on('end', function (result) {
console.log('search status: ' + result.status);
client.unbind();
});
}
});
https://github.com/ldapjs/dn/releases/tag/v1.1.0 has been published. Please update your dependencies and then code.
https://github.com/ldapjs/dn/releases/tag/v1.1.0 has been published. Please update your dependencies and then code.
so good, thanks a lot.
Please also update the npm of node-ldapjs, thanks a lot.
Please also update the npm of node-ldapjs, thanks a lot.
请问一下如何解析这个entry.dn,新建的账号dn带有中文是如何解析,我直接写中文,报错no such object
Hi, the "node-ldapjs" is very excellent and amazing, but I met some trouble when I client.search basedn, the Chinese String encode to the “gibberish”, why? and how can I do to decode? Thanks a lot.
"\e7\a0\94\e5\8f\91\e4\ba\8c\e7\bb\84"-> "研发二组"