Ssl – Connecting to a LDAPS server

ldapssltelnet

I am working on a development machine and I am trying to connect to my LDAP server. This is what I do –

telnet ldaps- 686

then the response is –

Could not open connection to the host
on port 686 : connect failed

But, the strange part is when I connect to my server –

telnet ldap- 389

then the connection is successful.

My question is, why does this happen?

Do I have to install SSL certificate on the client machine where I make the call from? I do not know much about this.

I know for a fact that the LDAP server is working fine because other applications are successfully using it currently.

Best Answer

  1. The LDAPS port is 636, not 686. Computers will call you out on attention to detail every time. Relentlessly.

  2. Telnet won't work on SSL ports. You should use the openssl client: openssl s_client -connect $ldap_host:636 -state -nbio 2>&1. That'll open the SSL connection, and leave you with a telnet like interface when you're done.