Re: [PATCH net 1/2] tcp: challenge ACK for non-exact RST in SYN-RECEIVED

From: Eric Dumazet

Date: Mon Jul 20 2026 - 12:49:53 EST


On Fri, Jul 17, 2026 at 10:15 AM Yuxiang Yang
<yangyx22@xxxxxxxxxxxxxxxxxxxxx> wrote:
>
> The SYN-RECEIVED request-socket path in tcp_check_req() accepts an
> in-window RST without requiring SEG.SEQ to exactly match RCV.NXT. A
> non-exact RST therefore removes the request instead of eliciting a
> challenge ACK.
>
> RFC 9293 section 3.10.7.4 applies the RFC 5961 reset check in
> SYN-RECEIVED: an exact RST resets the connection, while a non-exact
> in-window RST must trigger a challenge ACK and be dropped.
>
> Apply that check before the ACK-field validation, following the RFC
> sequence-number, RST, then ACK processing order. Factor the per-netns
> challenge ACK quota out of tcp_send_challenge_ack() so request sockets
> can share it. Use the request socket's send_ack() callback and its own
> out-of-window ACK timestamp to send and rate-limit the response.
>
> Reported-by: Yuxiang Yang <yangyx22@xxxxxxxxxxxxxxxxxxxxx>
> Reported-by: Yizhou Zhao <zhaoyz24@xxxxxxxxxxxxxxxxxxxxx>
> Reported-by: Ao Wang <wangao@xxxxxxxxxx>
> Reported-by: Xuewei Feng <fengxw06@xxxxxxx>
> Reported-by: Qi Li <qli01@xxxxxxxxxxxxxxx>
> Reported-by: Ke Xu <xuke@xxxxxxxxxxxxxxx>
> Fixes: 282f23c6ee34 ("tcp: implement RFC 5961 3.2")
> Cc: stable@xxxxxxxxxxxxxxx
> Signed-off-by: Yuxiang Yang <yangyx22@xxxxxxxxxxxxxxxxxxxxx>

Note : Please do not add a Reported-by: Yuxiang Yang
<yangyx22@xxxxxxxxxxxxxxxxxxxxx> if you are the patch author.

The amount of noise in this patch footer is quite annoying.

Reviewed-by: Eric Dumazet <edumazet@xxxxxxxxxx>