Knowing the difference in telnet responses could easily point you in the right direction when a telnet to a host on a particular port in unsuccessful.
There are a distinct differences in getting ‘refused’ or ‘timeout’ responses.
You will get a connection refused message for one of the following reasons:
- The application you are trying to test hasn’t been started/installed on the remote server.
- There is a firewall rejecting the connection attempt by terminating the connection setup.
Example output from a linux box:
The Connect failed message is the equivalent but from a window box :
The telnet command will abort the attempted connection after waiting a predetermined time for a response. This is called a timeout response. In some cases, telnet won’t abort, but will just wait indefinitely. This is also known as hanging. These symptoms can be caused by the one of the following reasons:
- The remote server doesn’t exist on the destination network. It could be turned off.
- The could be a routing issue, either the request or the response never gets to the destination.
- A firewall could be blocking the connection attempt, causing it to timeout instead of being quickly refused.
Here is an example of the output: