Question Bank - Computer Networks

Here's the question bank on all the computer networks topics.

Consider the three-way handshake mechanism followed during TCP connection establishment between hosts P and Q. Let X and Y be two random 32-bit starting sequence numbers chosen by P and Q respectively. Suppose P sends a TCP connection request message to Q with a TCP segment having SYN bit = 1, SEQ number = X, and ACK bit = 0. Suppose Q accepts the connection request. Which one of the following choices represents the information present in the TCP segment header that is sent by Q to P?

A.
SYN bit = 0, SEQ number = X + 1, ACK bit = 0, ACK number = Y, FIN bit = 1
B.
SYN bit = 1, SEQ number = X + 1, ACK bit = 0, ACK number = Y, FIN bit = 0
C.
SYN bit = 1, SEQ number = Y, ACK bit = 1, ACK number = X, FIN bit = 0
D.
SYN bit = 1, SEQ number = Y, ACK bit = 1, ACK number = X + 1, FIN bit = 0

Solution:

Answer: Option 4Concept: In TCP, for Connection Establishment 3-way handshake protocol is used.FIN bit : FIN bit is set while terminating the connection.Syn bit : Syn bit is used for initiating the request for connection establishment.Ack bit : Ack bit is used for indicating that the segment contains the acknowledgment.Sequence Number : In TCP , Sequence number used for counting each byte transferred in a particular connection and in each Segment Header, Sequence number field contains the Sequence number of first byte of data part of the Segment.Ack Number: In TCP , Ack number indicates the Sequence number of Byte expected next.Explanation:GIven: Next segment will be a piggybacked Acknowledgement segment So Ack bit = 1 and Q will increment the Sequence number ( which it received from P) put this into Ack Number field. Syn = 1 as Q will also establish the connection from Q to P and Sequence number will be Y(As given in Question).So , SYN bit = 1 SEQ Number = Y ACK bit = 1 ACK number = X+1 FIN bit = 0. Matches with Option 4.?

For more questions,

Click Here

Download Gyanm App

free current affairs for competitive exams

Scan QR code to download our App for
more exam-oriented questions

free current affairs for competitive exams

OR
To get link to download app

Thank you! Your submission has been received. You will get the pdf soon. Call us if you have any question: 9117343434
Oops! Something went wrong while submitting the form.