Article View: linux.kernel.netdev
Article #25783Re: [PATCH net v3] net: fix xfrm_state refcount underflow and leak in skb_ext COW
From: patchwork-bot+netdevbpf
Date: Wed, 02 Dec 2026 12:40
Date: Wed, 02 Dec 2026 12:40
32 lines
9291 bytes
9291 bytes
Hello:
This patch was applied to netdev/net.git (main)
by Paolo Abeni <pabeni@redhat.com>:
On Wed, 25 Nov 2026 10:07:17 +0800 you wrote:
> skb_ext_maybe_cow() re-acquires the SEC_PATH xfrm_state references for a
> copied extension chunk, gated on the source skb's active bit, while the
> release side (__skb_ext_put()) is gated on the chunk's
> offset[SEC_PATH].
>
> __skb_ext_del(SKB_EXT_SEC_PATH) on a shared chunk (refcnt > 1) only
> clears the skb's active bit: the chunk keeps offset[SEC_PATH] and
> sp->len, because the remaining sharers still use them. A later
> skb_ext_add() COWs such a chunk; the copy carries the SEC_PATH data, but
> with the active bit clear no references are taken for it. When the copy
> is freed, __skb_ext_put() puts sp->len references that were never
> acquired, underflowing the refcount of every xfrm_state in the sec_path.
> The state is destroyed while still hashed in the SAD and is dereferenced
> by later packet input. On v7.4-rc4, as an unprivileged user:
>
> [...]
Here is the summary with links:
- [net,v3] net: fix xfrm_state refcount underflow and leak in skb_ext COW
https://git.kernel.org/netdev/net/c/0f48b1d42710
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
Technical Details
Message-ID:
<179621520400.1432519.15947767262810728462.git-patchwork-notify@kernel.org>Path:
mbox-mo1.pugleaf.net!srv.newsdeef.eu.MISMATCH!feed-us-txt.newsdeef.eu!feed-us-ny.newsdeef.eu!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-375783-linux-kernel-netdev=dewy.ruReferences:
<20261125020718.261041-1-bsdhenrymartin@gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu.MISMATCH!feed-us-txt.newsdeef.eu!feed-us-ny.newsdeef.eu!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-375783-linux-kernel-netdev=dewy.ru From: patchwork-bot+netdevbpf@kernel.org Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net v3] net: fix xfrm_state refcount underflow and leak in skb_ext COW Date: Wed, 02 Dec 2026 12:40:04 +0000 Organization: Usenet Network Message-ID: <179621520400.1432519.15947767262810728462.git-patchwork-notify@kernel.org> References: <20261125020718.261041-1-bsdhenrymartin@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="1971266"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:2YAqvxXGSkeV2zdFFWvILk7JYzM= sha256:97bWepd6RfNNZ78QF6pCIGbzEbutN1LZ7cT3eaC10U4= sha1:bctIilufNiBkkVvwpzuFQn3Y2+s= sha256:n7IfnL3/7fvFC+78SdvGj1UdZ0ilL6mj7hdCB//RoHE= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id 66FCC117637; Wed, 2 Dec 2026 15:40:21 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.401 X-Spam-Status: No, score=-3.401 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id iDPemj0d2Ni3; Wed, 2 Dec 2026 15:40:17 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-375783-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id 1CE61117615; Wed, 2 Dec 2026 15:40:08 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sea.lore.kernel.org (Postfix) with ESMTP id 2DEA42BAC3; Wed, 2 Dec 2026 12:40:07 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1796215206; b=M3yd8EtMtBEwwZ94CNpNjV2KeIdVjGk7PFGE3riqmgnI132XRlRlGW47QGfvXdJv30aJ +Ji2m/it+0tkYkC72Nv9BYwItoa9gAdd7+QG25JYZzPaqOe+ab3ajuRq5GJ49/OlVDFFS j1vxIEHCASN3i/fuyZomLw0KuabXP8QVbBM3T2x+dDIjV3hoR/KehLTPW3knuJWUFkijQ t8RwuGY9RHmYNAUrFYsV5Z7VY8+9zn5I7m0xmsjLcDI9e1mo9ITjiyVsa0O3MZqeYt8yM 81NigP6/aOK6ZHKrBD75Y8hf+gvFSMfhamh07nrQ74x9o05JZbkzC/i3y4e1eyI6qnQ== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796215206; h=X-Original-To:Received:Received:DKIM-Signature:Received:Content-Type: X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe: List-Unsubscribe:List-Owner:Precedence:MIME-Version: Content-Transfer-Encoding:Subject:From:Message-Id:Date:References: In-Reply-To:To:Cc; bh=9TfxOg/nqP4ZG9Iy+Ppgawyfdbf7fGpKN9Nv8cI8tvI=; b=rj//bP69ZahcZVBSUEqzznekfydGhotUM1/3iPNkLLeVgHVpJ9iMPwBEdbo2vQxX7kXD Q4YMoKBo8QZfrMlRPjxPR5+sir2L9i/rBQ8Z5Cqv84rH/yqeMZTT7tUUZozHevgvL0Rcg ZLm+qPAbmu/JqgOeHXI/pR0ELqf0ke1otM01pfoNbuEISeXALfinC2uLCHUNaJNDj2bEl +TmA+knRhffhFcH/CZ34C6yZmYNC4zzQGoZNTe3Y+6Kt9miGdmDm9sXlMbotRxahujJGc vbOxSc51yq+N90X+RDFr+iUD9HIkG5XK36KjbFj5iFVMqRe5mDlSdrhVSIrYPoQ4ttQ== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Yw63Jsbr; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B0D67606A32F; Wed, 2 Dec 2026 12:40:06 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Yw63Jsbr X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796215205; b=wKNOBkQOXmvlPOUqDBGusb4dWhIfdRdDW0ULPMnnmPAiovjfBoyIyHMjXSx34mAeLfrx pTBBir0MLznnNX4/sO/dM03Yu4vsmmOmHCOSLBAwlaxMeRi2lXbnhijaL/Hu+EbrqTe4B c5h7VKVgWmACOJmVPa5o9lMDaoeriZwDc7rXZo7f0D8b7YD+rLSaivMtFkzdU2/2t0m32 BEbQx1yolsgk5dhDztzCabKs4AIHlwbPrhFXeByjRy25GiP/B5D44MjY/dYrbT0fty9C3 sUY2r+otQzCo+AWB2sDv36/dEFZtgHBY/FHq1uSxHuPjdWRLx5NuORrX5yZTLfkKypw== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796215205; h=Received:DKIM-Signature:Received:Content-Type:MIME-Version: Content-Transfer-Encoding:Subject:From:Message-Id:Date:References: In-Reply-To:To:Cc; bh=9TfxOg/nqP4ZG9Iy+Ppgawyfdbf7fGpKN9Nv8cI8tvI=; b=DnXhntrRoqELUKaUbX2vLCVf8S1dAIeRgAMVO4WsPnSvESNCCciNP9mGT/lCn7jwOSPQ 0bjcv0Ap42boQNFHLSbbFtol+XmXS4UrrLPDPi9+iwOnlpVPdZxuMUEJlr1yiZl3bM0qF S/k1yrCNi27PUq/PgReDYrvDS/9XEsqqalUo8psB+Z4Z2MdvmeQp1JDoL4a8/8L8uwISM tUQoTOGtJZ5YSxOZGBG6uLqh/B+8BRh387QKrAvTtJlHexKhCUlYFKm/gbtSJBH1KO88z yYtpvEwKOBSSOHWhyt2YC0Y01Ue2YW0hNWV/wo+csgaPhDNj+hK9lBPtifl3UlabFtw== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Yw63Jsbr; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CBACF606A323; Wed, 2 Dec 2026 12:40:05 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3C3AA1F0089A; Wed, 2 Dec 2026 12:40:05 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796215205; bh=9TfxOg/nqP4ZG9Iy+Ppgawyfdbf7fGpKN9Nv8cI8tvI=; h=Subject:From:Date:References:In-Reply-To:To:Cc; b=Yw63JsbraO0xX6OQif70h2/Kv/gW7aDWLAt2ORnRrzYhYIA530zoEbTrxzQPc6cqj lQYwdFuLCZOnOA4LXVs1y4Fka448nE6wsE8Gwvt/qenm1ntxdBcSBYz5qrRAmswjOh 9ouePdcoct7v8YYtvga9SlrhYwv22r0SWPUlrAtNrdatLOaxJDGdWxO0KJCnmazrrU GYteLOeMV2YNqRDdTbPDICdDsQsG1r+PNf4SROkQ+J1WJ+m48qmYVt9YU56ciQ6zwt VwM1vIQ2tfK/fr+z/1ObwlMRiR76hM9EYqrE1SiwlP9e4yMT5+myNI/K3AQTuaGHro T0neJYPRgiDcw== X-Received: from [10.30.226.235] (localhost [IPv6:::1]) by aws-us-west-2-korg-oddjob-rhel9-1.codeaurora.org (Postfix) with ESMTP id 346843808235; Wed, 2 Dec 2026 12:40:05 +0000 (UTC) X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list X-In-Reply-To: <20261125020718.261041-1-bsdhenrymartin@gmail.com> X-Cc: davem@davemloft.net, edumazet@kernel.org, kuba@kernel.org, pabeni@redhat.com, fw@strlen.de, steffen.klassert@secunet.com, herbert@gondor.apana.org.au, horms@kernel.org, netdev@vger.kernel.org, security@kernel.org, stable@vger.kernel.org