Re: [PATCH net] tcp: restore IPv6 af_ops on disconnect of a v4-mapped socket
From: Zhiyu Zhang
Date: Tue Nov 03 2026 - 06:40:11 EST
> Thank you for your contribution! Sashiko AI review found 1 potential
> issue(s) to consider.
>
> Critical: 0 · High: 1 · Medium: 0 · Low: 0
>
> If you believe none of the issues are legitimate, please reply to each
> issue of Medium severity or higher and explain why the AI is wrong.
> If any of them are legitimate and you plan to respin, please let patchwork
> know by including "pw-bot: cr" as a separate line at the end of your reply
> (one such reply per series is enough).
>
> - [High] The patch does not fully close the bug class it targets: an IPv6
> skb handed from the socket backlog to tcp_v4_do_rcv(), which then…
> ...
> Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261030032314.1978575-1-zhiyuzhang999%40gmail.com
Good catch, thanks. I can reproduce this by widening the window with a
socket filter.
For v3, I'll keep tcp_v6_disconnect() and make tcp_v4_do_rcv() drop
non-IPv4 skbs before interpreting TCP_SKB_CB(skb)->header.h4. The skb is
from the old connection, so dropping it seems safer than passing it to
tcp_v6_do_rcv(). This also covers the ACK path.
I have posted v3 at:
https://lore.kernel.org/netdev/20261103103633.2707416-1-zhiyuzhang999@xxxxxxxxx/
Could Eric or Kuniyuki please review it again?
Thanks!
pw-bot: cr