Question:

Consider the 3-way handshaking protocol for TCP connection establishment. Let the three packets exchanged during the connection establishment be denoted as P1, P2, and P3, in order. Which of the following option(s) is/are TRUE with respect to TCP header flags that are set in the packets?

Show Hint

In the TCP 3-way handshake, the first packet (P1) has only SYN set, the second packet (P2) has both SYN and ACK set, and the third packet (P3) has only ACK set.
Updated On: Apr 4, 2025
  • P3: SYN = 1, ACK = 1
  • P2: SYN = 1, ACK = 1
  • P2: SYN = 0, ACK = 1
  • P1: SYN = 1
Hide Solution
collegedunia
Verified By Collegedunia

The Correct Option is B, D

Solution and Explanation

In the TCP 3-way handshake:
P1 (SYN = 1): The first packet (P1) is sent by the client to initiate the connection, and it has the SYN flag set to 1.
P2 (SYN = 1, ACK = 1): The second packet (P2) is sent by the server to acknowledge the client's request. It has both SYN and ACK flags set to 1.
P3 (ACK = 1): The third packet (P3) is sent by the client to acknowledge the server's response. It has only the ACK flag set to 1.

Thus, options (B) and (D) are correct:
(B) P2: SYN = 1, ACK = 1.
(D) P1: SYN = 1.

Why Other Options are Incorrect:
Option (A): Incorrect because P3 only has the ACK flag set, not both SYN and ACK.
Option (C): Incorrect because P2 has both SYN and ACK flags set, not just ACK.
Was this answer helpful?
0
0

Questions Asked in GATE CS exam

View More Questions