What is TCP (Transmission Control Protocol)?

TCP (Transmission Control Protocol), in the late 1960s and early 1970s, networks were not designed to share resources between different networks.

What is TCP (Transmission Control Protocol)?

What is TCP Protocol in Networking?

Since then, it has become increasingly necessary for user apps to share resources. But to do this, network administrators must first agree on a set of common technologies and standards for networks to communicate. For this reason, applications such as file transfer and e-mail should also be standardized to allow interaction between user applications. The Transmission Control Protocol has been developed with these targets.

The main purpose of TCP is to provide reliable logic circuits or connection services between transaction pairs. This does not mean reliability from lower-level protocols (such as IP), so it should guarantee this alone.

TCP is located at the transport level of the traditional level model. It is located between IP and higher levels and is not uploaded to gateways. It is designed to stay on computers or machines interested in maintaining the integrity of data transfer between endpoints. Most commonly, this protocol is available on user computers. Since IP is a connectionless network, it is the TCP that should be responsible for the reliability, flow control, sorting, openings, and closing tasks.

Although TCP and IP are so closely related, although they are called “TCP/IP” together, they can support other protocols. For example, it can work with another non-connection-oriented protocol, such as ISO 8473 (Connection-Oriented Network Protocol or CNLP) (if some interface settings are made between the modules). In addition, application protocols such as Simple Mail Transfer Protocol (SMTP) are supported by many services provided by TCP.

TCP’s Main Features

The TCP protocol offers a higher level of services and is a connection-oriented protocol, meaning it keeps track of the status of each chain of user data passing through it.

The term used in this context also means that it is responsible for transferring the TCP by the network or networks to the receiving user application (or high-level protocol) between endpoints. Thus, he must ensure that the data is correctly transmitted and received by computers on the respective networks. Since TCP is a connection-oriented protocol, it is responsible for the reliable transmission of every character (byte or octet) it receives from the corresponding top level. As a result, it uses and accepts/rejects sequence numbers.

The term associated with these aspects of connection-oriented protocols is a virtual circuit. A sequence number is added to each octet transmitted. The receiving TCP module uses a checksum procedure to check the possible presence of data damage generated in the transmission process. If the data is acceptable, it sends a positive meaning (ACK) to the TCP sending module. If the data is corrupted, the receiver discards the data and uses a sequence number to report the problem to the sending TCP. Like many other connection-oriented protocols, TCP uses timers to ensure that it does not take too long before transmissions from the receiving node and/or data transmission from the transmitting node.

The transmission control protocol retrieves data from a high-level protocol for a string. This is different from many other protocols used in the industry. String-oriented protocols are designed to send separate characters, not blocks, frames, datagrams. The data is sent by a higher-level protocol in the form of strings in bytes. when they reach the level, the bytes are grouped together to form TCP segments. These segments are transferred to IP (or another low-level protocol) for transfer to the next destination. The length of the partitions is determined by TCP, but the developer of a particular system can determine how TCP decides.

TCP developers working with block-oriented systems such as IBM operating systems may need to slightly change their thinking about TCP capabilities.

It supports the use of variable-length segments thanks to its string-oriented design. Therefore, applications that typically work with fixed-length data blocks (a staff management application that sends fixed-length employee records or a payroll management application with fixed-length pay records) cannot use TCP to transmit fixed blocks to the receiver. The application-level should deal with configuring blocks within TCP strings.

The transmission control protocol also controls the copying of the data. If the sending TCP decides to retransmit data, it discards unnecessary data. This unnecessary data may appear on the network, for example, when the receiver does not accept TCP traffic on a scheduled basis, in this case, the sending TCP decides to retransmit the data. In addition to the chain transmission capacity, it supports the concept of a push function. This function is used when an application wants to ensure that all data transmitted to a lower level is transmitted.

To do this, it manages buffer management. To achieve this functionality, the top-level protocol sends a command to TCP with a push parameter identifier to 1. This indicates that TCP will send all stored traffic to its destination in the form of a segment or segment. In addition to using sequence numbers for assumptions, TCP also uses it to reorder segments that are unusual to their destination, and it is quite possible to create duplicate datagrams in the network as it is based on a protocol that is not link-oriented.

TCP also eliminates duplicate segments. TCP uses a comprehensive acceptance scheme. The acceptance number accepts all octets until the acceptance number is negative (and included). This scheme is a very simple and effective method of accepting traffic, but it has one drawback. For example, let’s assume that ten episodes have been transmitted and that they are out of order due to actions taken during the routing process. TCP should only accept the maximum number of contiguous bytes received without errors. It is not allowed to accept the highest bytes received until all intermediate bytes have arrived.

Therefore, as with any other connection-oriented protocol, the acknowledgment timeout may expire, and TCP forwarding resends traffic that has not yet been accepted. These retransmissions can add significant overhead to the network. The receiver TCP module is also responsible for controlling the flow of data from the transmitter, which is very useful to prevent the overflow of storage devices and saturation of the receiving machine. The idea that TCP uses is somewhat unusual in communication protocols. This is based on sending a “window” value to the transmitting device. The transmitter is allowed to send an equal number of bytes to the value of its window. When this value is reached, the window closes and the transmitter must stop sending data. Also, it has a very useful feature that allows you to replicate multiple user sessions on the same computer. This is done by defining some rules for sharing ports and sockets between users.

TCP provides full-duplex mode transmission between communicating entities. In this way, the gearbox can be carried out in both directions without waiting for the direction change indicator signal required in half-duplex gearboxes. It also allows users to set security levels and connection priorities. Although these options are not included in all TCP protocols, they are defined in the TCP standard. It provides a secure shutdown of virtual circuits (the logical connection between two users). A safe shutdown ensures that all traffic is recognized before the virtual circuit is disabled.

Active and Passive Clearances

It ports can establish two types of connections. Passive open mode allows the high-end protocol (such as a server) to tell TCP and the computer’s operating system that instead of sending an active open, connection requests will wait from the remote system.

When this request is received, the operating system assigns a port number for this purpose. This utility can be used to communicate with remote users without explicit latency enabled. Application processes requesting passive opening can accept a request from any user (assuming some compliance requirements are met).

If any calls are acceptable (without compatibility requirements), the external socket number is reset. Outer socket numbers not specified are only allowed in passive openings. The second form of connecting is an active open mode. In this case, the higher-level protocol specifically determines another socket for connection. Typically, the active aperture is sent to a port that opens passively to create a virtual circuit.

It supports a scenario where two active vulnerabilities are sent from one system to another simultaneously and establish the connection. This feature allows applications to send an opening at any time, regardless of whether the other application has sent another opening.

It sets strict rules on how passive and active openings should be used together. First, an active vulnerability defines a particular socket as well as its priority and security levels. It guarantees opening if there is a compatible passive opening in the remote socket or it has sent a compatible active opening.

The Transmission Control Block (TCB)

Since TCP needs to remember a few things about each virtual connection, it stores this information in the Transmission Control Block (TCB). Among the information stored in TCB, it highlights local and remote socket numbers, pointers to send and receive buffers, pointers to retransmission queue, security and priority values ​​of the connection, and segment in progress.

TCB also includes several variables associated with send and receive sequence numbers. PDUs that are exchanged between two TCP modules are called segments. The segment is divided into two sections, the title section, and the data section. The data section follows the title section. The first two fields in the segment are called the source port and destination port. These 16-bit fields define the highest-level application programs using the TCP connection.

TCP Segment (PDU)

The next field is called the sequence number. This field contains the sequence number of the first octets of the user data field. Its value specifies the location of the bit string of the transmitter module. Specify the first octets of user data within the segment. The sequence number is also used during the connection management process. If two TCP entities use the link request segment, the sequence number specifies the first send sequence number (ISP) to be used for the next enumeration of user data.

The value of the acceptance number allows the acceptance of previously received data. This field contains the value of the sequence number of the next octet expected to be received from the transmitter. Using this definition provides inclusive acceptance, in the sense that it allows the acceptance of all octets up to minus 1, including this number. The data offset field specifies the number of 32-bit aligned words consisting of the header.

This field is used to determine where the data field starts. As expected, the reserved area is reserved. It consists of 6 bits that should be zero. These bits are reserved for future use. The next six bits are called flags. These are control bits and are used to identify specific services or utilities that can be used during the session. The value of some of these bits shows how to interpret other fields in the header. The six bits mentioned bearing the following information.

  • URG indicates that the urgency marker area is important.
  • ACK indicates whether the acceptance area is important.
  • PSH means that the module will use the push function.
  • RST indicates that the connection will start.
  • SYN indicates that the sequence numbers will be synchronized; It is used as an indication that some setup operations will be performed in the connection setup segments.
  • END indicates that the sender has no other data to send. In other protocols, it can be compared to the end of the transmission signal (EOT).

The next field, called the window, is set to a value that indicates how many octets the receiver wants to accept. This value is determined to take into account the value (acceptance number) of the acceptance area. The window is created by adding the window field and the acceptance number field values. The checksum field contains a 1 to the 16-bit complement of the 1-complement of the sum of 16-bit words in the segment, including the text header. The purpose of this calculation is to determine whether the segment from the transmitter is error-free. The next field, called the emergency pointer in the segment, is used only if the URG flag is 1.

The purpose of this marker is to identify the data octet and then the emergency data. Emergency data is called out-of-band data. It does not say what to do with emergency data because it depends on the application. In other words, only the place where the emergency data begins is specified, not what to do with it.

The value in this field is an offset to the sequence number and indicates the octet tracked by the emergency data. The options area is designed to allow future enhancements. Similar to the options field of IP datagrams, a byte indicating the option number of each option is a field containing the length of the option, and finally the option itself.

Currently, the use of option space is very limited, and the TCP standard specifies only three options:

  • 0: end of option list
  • 1: no action
  • 2: maximum segment size

Finally, as shown in the figure, user data is below. Internet protocols have become one of the most used protocol families in the world.

It is designed to facilitate the communication of computer networks. Internet protocols consist of many protocols designed to support communication between networks. In addition, network protocols include many application-level protocols such as TELNET, File Transfer Protocol (FTP) and Simple Mail Transfer Protocol (SMTP).

   Related Articles


What is WAN?
Cisco History
What is EGP?
What is a MAN?
What is VoIP?

Add a Comment

Your email address will not be published. Required fields are marked *

error: