Transmission Control Protocol Flashcards

1
Q

Overview of TCP

A

TCP is a connection-oriented protocol, meaning it requires a connection to be established before data can be sent. This is achieved through a process known as the “three-way handshake.” TCP is also designed to provide reliable communication. It ensures that data is received in the order it was sent and without any errors. This reliability is achieved through sequence numbers, acknowledgments (ACKs), and checksums.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Key Features of TCP

A
  • Reliable, in-order delivery: TCP rearranges data packets in the order they were sent and manages retransmissions if packets are lost.
    Error checking: TCP uses checksums to ensure that data is not corrupted in transit.
  • Flow control: TCP uses window sizes to control how much data can be sent at a time to ensure that the receiver is not overwhelmed.
  • Congestion control: TCP detects congestion in the network and reduces the data transfer rate to alleviate it.
  • Connection-oriented: A TCP connection is established before data can be sent, using a three-way handshake.
  • Full duplex: Data can flow in both directions simultaneously on the same connection.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

TCP Segment Structure:

A

A TCP segment consists of a header and a data section. The header contains fields like source and destination ports, sequence and acknowledgment numbers, flags, window size, checksum, and urgent pointer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Sequence and Acknowledgment Numbers:

A

These numbers are critical for ensuring the orderly and reliable delivery of segments. Sequence numbers are used to number the bytes in a stream of data from sender to receiver, while acknowledgment numbers are used to confirm receipt of data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Connection Management:

A

TCP connections are established using a three-way handshake process. This involves:
- SYN: Initiating connection request.
- SYN-ACK: Acknowledgment of the connection request along with the connection request from the other side.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Flow and Congestion Control:

A

TCP adjusts the rate of data flow based on the network conditions. It uses techniques like sliding windows and congestion avoidance algorithms (like TCP Tahoe, Reno, or New Reno).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Closing a Connection

A

TCP connections are terminated through a four-way handshake, ensuring that both sides of the connection are cleanly shut down:

One end sends a FIN packet.
The other end acknowledges with an ACK and sends its own FIN.
The original sender completes the termination with a final ACK.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly