Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am doing some trouble shooting on an application that listens on tcp 443. This particular application talks via SSL. I wanted to connect to it with netcat. Is this possible?

Note: I'm not asking if netcat can encrypt its traffic.

share|improve this question
Yes, netcat will be able to connect to it but that's it. You won't see any traffic because your client cannot send the initial SSL client setup. Is your goal to see if the TCP port is listening for connections? – Bort Feb 6 '13 at 15:34
up vote 10 down vote accepted

You should use openssl s_client -connect server:port to debug applications over SSL connections.

share|improve this answer
openssl can do TLS that way too with -starttls <protocol> – fuero Feb 6 '13 at 16:48
Unfortunately openssl s_client doesn't support IPv6. If that's important you can use ncat (part of nmap). – Gerald Combs Feb 6 '13 at 16:59

You probably want to make use of the openssl s_client -connect command.

However it looks like this doesn't accept piped input as you might use with netcat.

If the application is just an HTTP server then you can use standard terminal entry to perform your session.

share|improve this answer

netcat doesn't support SSL. You can still use it to test whether you can establish a TCP connection, but not much more. Aside from the already suggested openssl s_client, you can use ncat (from nmap) or socat. ncat is very similar in usage to netcat, socat has a different syntax and is much more powerful, but should be able to do the same job.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.