Various computer networks are connected with one another via the internet. In order to build up such connections, both the sending as well as the receiving systems have to provide transfer interfaces, or ports. Netstat allows you to find out which ports are opened by your own system and which active connections exist — all of this helps reduce the risk of undesired access attempts.
Telnet is a client-server protocol based on character-oriented data exchange over TCP connections. Telnet enables remote control of computers via text-based inputs and outputs. For this reason, a client-server connection is established as a default via the TCP protocol and port 23, where the remote-controlled device acts as a server and waits for commands. The Telnet client, the controlling instance in this process (also referred to as remote access or login), can be installed on a particular device, as well as on an ordinary computer. However, the presentation of the transmitted information differs, depending on the device. This protocol can also be used to manage applications that do not have a graphical interface.
As early as 1969 (during the nine months of work on ARPANET), the development of Telnet (Teletype Network) was practically completed. But it was only in 1973 that the protocol allowing access to remote computers first received its final specification in RFC 495 (Request for Comments). It was implemented by most platforms as the official standard of the Internet Engineering Task Force (IETF). The kernel protocol and the basic working methods and extensions are characterized in the more recent standards RFC 854 and RFC 855.
- How and where is Telnet used?
- The Telnet standard commands
- The advantages and disadvantages of the Telnet protocol
- How to activate Telnet and use in on your system
How and where is Telnet used?
One of the main reasons for developing the remote protocol was that computer systems at that time were still really expensive and not easily accessible for everyone. Another reason was their extreme size, which meant that they were bound to specific locations. In order to make computer resources available at universities and companies, Unix was developed at the end of the 1960s as a suitable operating system and Telnet as an appropriate protocol service. This meant that any user that had the right authorization, could start, manage, and use applications on the powerful large computers for their own personal use.
Access to databases
Over many years, Telnet also played a crucial role for institutions that work with large databases: for example, in libraries, the protocol was an elementary building block of online catalogs published in the 1980s, which are better known as OPAC (Online Public Access Catalog). Initially, these digital publication databases, which followed the traditional card catalogs, were still accessible in the libraries’ local networks via terminals. As the internet started becoming more and more successful, it was also possible to access them via locally usable web interfaces, whose communication means was supported by the Telnet protocol in many cases.
Interaction with programs on application servers
Another deployment scenario, for which Telnet clients were typical, was the access to text-based programs on an application server. For example, the Free Internet Chess Server can still be used today via Telnet connections. Using text input, you can select from the available opponents and also move your pieces around the board. Meanwhile, graphical interfaces such as the Jin Applet or Javaboard, which enable playing pieces to be moved with the mouse, have replaced the text-based input.
Administration of networks and servers
Telnet has always been a practical protocol for network and server administrators. The ability to remotely manage devices on the network is ideal for administration tasks, especially because the protocol is supported by almost all devices. It can also be used to check the availability of certain ports or to detect errors on e-mail servers (SMTP, port 25) by sending an e-mail directly from the server. The Telnet solution is an effective method for configuring servers e.g. a web server: changes to the directory structure, the file access rights, or the password, can be implemented quickly and easily.
The Telnet standard commands
There are some generally valid commands for the connection protocol that clients implement by default. They are usually the same or similar on Telnet-supported platforms such as Unix, Windows, and Linux. Using the command
the connection setup is started, which is completed after the username and password have been entered. The prerequisite for using Telnet is that the control device has user recognition. The entry hostname represents the device name in the network, and you can also specify the correct IP address and connection request through the desired port:
telnet ip-address port number
The following table shows the other standard commands that you can partially extend with arguments and execute using the Telnet client:
|?||Calls up the help menu|
|close||Ends the Telnet session|
|display argument||Displays the various parameters for the current connection (port, terminal type, etc.)|
|environ argument||Defines variables for the respective operating system environment|
|logout||Ends the current Telnet session as long as the remote host supports the logout option|
|mode type||Specifies the transmission type (text file, binary file)|
|open hostname||Builds an additional connection to the selected host on top of the existing connection|
|quit||Ends the Telnet client connection including all active connections|
|send argument||Sends selected, typical Telnet character strings to the host|
|set argument||Changes the connection parameters|
|unset||Loads the pre-defined connection parameters|
The advantages and disadvantages of the Telnet protocol
Since Telnet connections are practically standard TCP connections, the client can be employed to use or test other services that rely on TCP as a transport protocol. For example, with a simple request, you can check the functionality of an HTTP server or (as mentioned earlier) the status of an e-mail server. This versatility is enhanced by the fact that the connection protocol can be used across platforms. There are only a few devices that do not support the official IETF standard. Whether or not the client and server computers rely on the same operating system is also irrelevant. A further advantage of Telnet is that it allows unrestricted access to a controlled system’s resources if permission has been given.
The latter point, however, presents a high-security risk when combined with a previously unmentioned disadvantage: neither the connection setup nor the data transmission is encrypted when the Telnet protocol is used. All information you send can, therefore, be intercepted by third parties in plain text, including the login information required for remote access. This means that hackers won’t have much trouble taking over the system.
An overview of the advantages and disadvantages:
|Telnet client is versatile||Unencrypted data exchange|
|Can be used cross-platform||Full access makes it easier for hackers|
|Unlimited access to target resources||Only few servers can be reached via Telnet|
How to activate Telnet and use in on your system
Simple Telnet clients are installed by default and are usable on many popular, network-capable operating systems. However, different steps are required to start the respective application, depending on which system you have. For example, the client needs to be activated first on Microsoft operating systems, at least since Windows Vista. In the following paragraphs, we have summarized some step-by-step instructions for the most important systems.
Telnet on Windows 7
If you are using Windows 7 and are trying to connect to a Telnet server through the input request, you are likely to encounter an error message explaining that the Telnet command is not recognized or could not be found. The reason for this notification is that the service is disabled by default. However, you can activate it in just a few simple steps:
- From the Start Menu, open the Control Panel and click on 'Programs', or 'Programs and Features' if you are using the classic display version. In the newly opened window, select 'Turn Windows features on or off'.
- After it’s loaded, the list of available Windows services will open. Search for the 'Telnet Client' item, check the box, and confirm the selection by clicking on 'OK'.
- The client is now activated, although this can take a few moments.
- Now you can connect to the Telnet server of your choice. To do this, first, open the command prompt and enter 'Telnet' in order to start the client. Alternatively, you can find it via the search box entitled 'Search programs/files'. Then, start the connection setup as you desire e.g., by specifying the IP address of the target device just as in the following screenshot.
Telnet on Windows 8
Telnet is also disabled by default on Windows 8. Attempting to access the client or establish a connection will result in you receiving the same error message as Windows 7 users receive, stating that the Telnet command is either misspelled or cannot be found. Even when the remote service is activated, the approach is essentially the same.
- From the Start Menu, go to the Control Panel, select the 'Programs' or 'Programs and Features' option and click on 'Turn Windows Features on or off'.
- In the features overview, search for the Telnet Client and check the box next to it.
- The activation process will begin after clicking on 'OK'. Once this has been completed, the system will send you a success report.
- The client is activated and can be accessed and operated using search commands or the input prompt.
Telnet on Windows 10
Like its predecessors, Windows 10 has the remote program by default, but it’s disabled. You can set up the client and operate it using the tried and tested pattern.
- The first step is to open the overview of installed programs and features. For this purpose, access the system control via the start menu or enter [Windows key] + [X] on your keyboard. Next, select 'Programs and Features'.
- Select 'Turn Windows features on or off' and activate the Telnet Client by checking the appropriate box and confirming your selection by clicking 'OK'.
- After a short loading process, you will be notified that Telnet has been successfully activated and is ready for use.
- Start the client, just like with the previous versions, by using the input prompt or the search box.
Telnet on macOS
As a macOS user, you can also access the Telnet Client’s services to remotely control selected computer systems. Unlike the Microsoft systems, the service is enabled by default here, so you can start using it right away. For this purpose, you only need the terminal application – Apple system’s command line tool.
- To open the terminal application, first, open the Finder and select 'Programs' or 'Applications' in the left-hand menu. In the 'Utilities' folder, you will find the terminal connection, which enables you to open the command line by double-clicking.
- Now you can create the desired remote connection by entering the 'Telnet' command in combination with the respective host address. Alternatively, you can set up a connection via the 'Shell' item in the top menu bar. To do this, select the 'New Remote Connection…' option from the drop-down menu, and then select 'Telnet' as the desired service.
When it comes to remote connections, the Telnet protocol has been top of the list for a long time thanks to being practical and simple to operate. However, growing demands regarding the security of managed and transmitted data have made the protocol unsuitable and unacceptable for many scenarios. Remote connections on the internet today are mainly based on the encrypted SSH protocol (Secure Shell), which is a much safer protocol thanks to its public-key authentication. However, Telnet is still a suitable solution for devices with limited operating systems that do not enable SSH server operation. A popular client software that simplifies remote access based on both protocols is PuTTy.