ashwani thapa
ashwani thapa

Reputation: 21

If TCP runs out of its sequence number, what will happen ? if it is 0 again, will that byte not be considered duplicate?

If TCP runs out of its sequence number, what will happen? If it again turns to 0 as the sequence number of the next byte, won't that be considered "duplicate" by the receiver?

If yes, then it has to ignore that byte. If not, why?

Upvotes: 1

Views: 464

Answers (1)

ashwani thapa
ashwani thapa

Reputation: 21

I think, i found the answer. The answer of this query, lies on one of the TCP option field known as "timestamp". It's in every TCP segment (including data and ACK segments).

Therefore to identify a unique tcp segment, we look for a combination of "timestamp" and "sequence number".

The basic idea is that a segment can be discarded as an old duplicate if it is received with a timestamp less than some timestamp recently received on this connection.

Example : Two segments 400:12001 and 700:12001 definitely belongs to two different incarnations.

And this mechanism is known as "PAWS" or protection against wrapped sequence numbers.

Reference: https://www.rfc-editor.org/rfc/rfc1323#page-17

Upvotes: 1

Related Questions