TELNET


USING THE POWER OF TELNET COMMAND

Telnet is a network protocol used on the Internet or local area networks to provide a bidirectional interactive text-oriented communication facility using a virtual terminal connection. User data is interspersed in-band with Telnet control information in an 8-bit byte oriented data connection over the Transmission Control Protocol (TCP).

The Telnet commands allow you to communicate with a remote computer that is using the Telnet protocol. You can run Telnet without parameters in order to enter the Telnet context, indicated by the Telnet prompt (Microsoft Telnet>). From the Telnet prompt, use the Telnet commands to manage a computer running Telnet Client.

description

description

Telnet is a client-server protocol, based on a reliable connection-oriented transport.

Typically this protocol is used to establish a connection to Transmission Control Protocol (TCP) port number 23, where a Telnet server application (telnetd) is listening.

To know more on the List of TCP and UDP port numbers [Official, Unofficial, Multiple use] : http://en.wikipedia.org/wiki/List_of_TCP_and_UDP_port_numbers

INTERNET PROTOCOLS

Application layer:
DHCP DHCPv6 DNS FTP HTTP IMAP IRC LDAP MGCP NNTP BGP NTP POP RPC RTP RTSP RIP SIP SMTP SNMP SOCKS SSH Telnet TLS/SSL XMPP (more: http://en.wikipedia.org/wiki/Category:Application_layer_protocols)

Transport layer:
TCP UDP DCCP SCTP RSVP (more: http://en.wikipedia.org/wiki/Category:Transport_layer_protocols)

Internet layer:
IP IPv4 IPv6 ICMP ICMPv6 ECN IGMP IPsec (more: http://en.wikipedia.org/wiki/Category:Internet_layer_protocols)

Link layer:
ARP/InARP NDP OSPF Tunnels L2TP PPP Media access control Ethernet DSL ISDN FDDI (more: http://en.wikipedia.org/wiki/Category:Link_protocols)

HOW TO CLOSE AN ACTIVE TELNET CONNECTION?

Linux:
After programme has completed its execution and returned a response, you can hit enter twice to close the connection.

In case the response is taking longer, the terminal will show a “C:ANSI>” (character) to close connection.
To close the telnet connection, “CTRL” + ” ] ” or “CTRL” + ” ^] ” have to be pressed.

Note: One should never use “CTRL” + “C”.

Windows:
in windows its a little tricky but not hard, to end your current telnet connection
Point the cursor on telnet prompt and type quit.

Following are the steps to quit (Prompt: Microsoft Telnet>):
1. Open the telnet prompt by holding down the “Ctrl” key and push the ‘]’ key.
2. Type “quit”.
3. Push the “Enter” key.

EXAMPLE

Linux:

$> telnet <host_domain_name>
Trying <host_domain_name>...
 Connected to <host_domain_name> (<host_domain_IP_address>).
 Escape character is '^]'.
GET /index.php?id=12323&action=news HTTP/1.1
 Host: <host_domain_name>
 Cookie: <cookie_info>
 Connection: close
O/P
HTTP/1.1 200 OK
 Date: Sun, 20 Jan 2010 09:10:42 GMT
 Server: Apache
 Vary: Accept-Encoding
 Content-Length: 7
 Connection: close
 Content-Type: text/html
Success

Note: always add connection close explicitly or else the multiple connections will be left open and unused

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s