Repository navigation
tcp: update TS.Recent from a zero-window probe - #15291
Merged
Merged
Conversation
A one-byte zero-window probe at RCV.NXT fails the acceptability check and is answered through maybeSendOutOfWindowAck before TS.Recent is updated, so the ACK echoes the TSval of the last data segment accepted before the window closed. RFC 7323 section 4.3 rule 2 updates TS.Recent from any segment with SEG.SEQ <= Last.ACK.sent, so update it for a probe at RCV.NXT before sending the out-of-window ACK. Fixes gvisor#15143
copybara-service Bot
pushed a commit
that referenced
this pull request
Oct 8, 2026
Fixes #15143. A one-byte zero-window probe at RCV.NXT fails the acceptability check in `rcv.go`. The endpoint answers it with an out-of-window ACK before TS.Recent is updated. That ACK echoes the TSval of the last data segment accepted before the window closed. RFC 7323 section 4.3 updates TS.Recent from any segment with SEG.SEQ <= Last.ACK.sent. This change updates TS.Recent for a probe at RCV.NXT when timestamps are enabled, then sends the ACK. Testing: - New `TestTimeStampZeroWindowProbe` in `tcp_timestamp_test.go`. Without the `rcv.go` change it fails with `got = 101, want = 201`. - `tcp_timestamp_test` (7/7), `tcp_test` and `rcv_test` pass locally under bazel. FUTURE_COPYBARA_INTEGRATE_REVIEW=#15291 from adi-IL:bot/gvisor-15143 8f6f546 PiperOrigin-RevId: 993349680
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #15143.
A one-byte zero-window probe at RCV.NXT fails the acceptability check in
rcv.go. The endpoint answers it with an out-of-window ACK before TS.Recent is updated. That ACK echoes the TSval of the last data segment accepted before the window closed.RFC 7323 section 4.3 updates TS.Recent from any segment with SEG.SEQ <= Last.ACK.sent. This change updates TS.Recent for a probe at RCV.NXT when timestamps are enabled, then sends the ACK.
Testing:
TestTimeStampZeroWindowProbeintcp_timestamp_test.go. Without thercv.gochange it fails withgot = 101, want = 201.tcp_timestamp_test(7/7),tcp_testandrcv_testpass locally under bazel.