From: "Chris Mason" <mason@kernel.org>
To: ast@kernel.org, daniel@iogearbox.net, andrii@kernel.org,
bpf@vger.kernel.org, netdev@vger.kernel.org
Cc: eddyz87@gmail.com, memxor@gmail.com, martin.lau@linux.dev,
song@kernel.org, yonghong.song@linux.dev, jolsa@kernel.org,
emil@etsalapatis.com, ihor.solodrai@linux.dev,
john.fastabend@gmail.com, sdf@fomichev.me, davem@davemloft.net,
edumazet@kernel.org, kuba@kernel.org, pabeni@redhat.com,
willemb@google.com, horms@kernel.org, nhudson@akamai.com,
linux-kernel@vger.kernel.org, mason@kernel.org
Subject: [PATCH bpf 0/2] bpf: fix skb->transport_header after a decap
Date: Sat, 05 Dec 2026 07:56:13 -0500 [thread overview]
Message-ID: <20261205012513.15379-1-mason@kernel.org> (raw)
Hi everyone,
These are AI generated fixes for two bugs in my commit 33be492c2e23 ("bpf: Use
the inner transport header after a decap"). A decap with bpf_skb_adjust_room()
can move skb->transport_header to the wrong place.
- Patch 1: nobody has set the inner transport header, and its offset has
wrapped. The kernel drops valid GSO packets then.
- Patch 2: ESP still has to encrypt the packet. It gets corrupted or dropped,
and a very short one can hit a BUG().
AI generated tests reproduce both bugs on v7.4-rc5, and pass with the patches.
7.3.7 has both bugs too.
This is on top of v7.4-rc5.
Chris Mason (2):
bpf: Don't use an unset inner transport header
bpf: Keep skb->transport_header for ESP offload
net/core/filter.c | 19 ++++++++++++++-----
1 file changed, 14 insertions(+), 5 deletions(-)
base-commit: fe6ff8d5d675c01793b9f051d16055dd4aa75244
next reply other threads:[~2026-12-05 12:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-05 12:56 Chris Mason [this message]
2026-12-05 12:57 ` [PATCH bpf 1/2] bpf: Don't use an unset inner transport header Chris Mason
2026-12-05 13:30 ` sashiko-bot
2026-12-05 14:32 ` Chris Mason
2026-12-05 12:58 ` [PATCH bpf 2/2] bpf: Keep skb->transport_header for ESP offload Chris Mason
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261205012513.15379-1-mason@kernel.org \
--to=mason@kernel.org \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=eddyz87@gmail.com \
--cc=edumazet@kernel.org \
--cc=emil@etsalapatis.com \
--cc=horms@kernel.org \
--cc=ihor.solodrai@linux.dev \
--cc=john.fastabend@gmail.com \
--cc=jolsa@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.lau@linux.dev \
--cc=memxor@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=nhudson@akamai.com \
--cc=pabeni@redhat.com \
--cc=sdf@fomichev.me \
--cc=song@kernel.org \
--cc=willemb@google.com \
--cc=yonghong.song@linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.