[Date Prev][Date Next] [Chronological] [Thread] [Top]

SSL based LDAP client verification



Hi all,

I have followed this link to generate self-signed certificates. I have successfully performed server side validation. What if i want to access LDAPS:// from other client. I have copied servercrt.pem and serverkey.pem file on client machine, also added servercrt.pem file to client trust store. I'm using LDAPjs client for authentication. I have provided trust store path and serverkey.pem file in the code, but i still get the following error: 

crypto.js:104
  if (options.cert) c.context.setCert(options.cert);
                              ^
Error: error:0906D06C:PEM routines:PEM_read_bio:no start line
    at Object.exports.createCredentials (crypto.js:104:31)
    at Object.exports.connect (tls.js:1334:27)
    at Client._connect (/home/aneela/node_modules/ldapjs/lib/client/client.js:736:18)
    at new Client (/home/aneela/node_modules/ldapjs/lib/client/client.js:247:22)
    at Object.createClient (/home/aneela/node_modules/ldapjs/lib/client/index.js:60:12)
    at authDN (/home/aneela/client-ldapjs/app.js:15:21)
    at Object.<anonymous> (/home/aneela/client-ldapjs/app.js:90:1)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)

Please guide me if i'm doing something wrong. Which PEM files need to be copied on client machine? Or i need to create client side certificates separately as well?