Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8AC5936C9EC for ; Thu, 25 Jun 2026 09:44:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782380692; cv=none; b=HZzZeUlDitcg6j56ozmOehl6NGhoKkMD1LOtOvTzHlOkghSxelLYpc4/a4FXuLCBpXgmdvxcSVRX3XgEkzBX/m2h9eNEjLmsM875121yBpvIi+sxKIZMtECaOaexVf1wmnQj3ZGUmsj15DKmadZQ9yymzptoMGwNAfNb4yZ73+k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782380692; c=relaxed/simple; bh=/BNwaXOeU1cjHYoVohiLjNQQgWiZ6epL1zFwXlJLI7E=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type; b=uPzz8+dkftKYZewzdJptlsh6WDKAgjtM818MTq5bZK6P+A9faFbwtBNQ1NmKPy2WkJ02FbtUgsnsIRP2Jgh213T5k/T7H0DtFeNt+DLkJkxb8nFPRtfzUgBeH6C3gI59UmN8qXQUSrurFuBic17TfBRyxDEOWfZj9N6n7sP4UCI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=0U7OEsnb; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="0U7OEsnb" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B0FF31F000E9; Thu, 25 Jun 2026 09:44:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1782380691; bh=MhwgAU4bgQdfPXxWQtrGXH+pBn4zY3XwFIQ7bJZ80GU=; h=From:To:Cc:Subject:Date:Reply-To; b=0U7OEsnbUvYrdATUo6xJcCxralJoPJdtur9ZgectPCgkHQP8gDB4OAcYXuTXHmZ3e fDrZOa1eDCRH4qQ/r3D5UeeOJiQeNjXO+vYJyCFQAMpLlw3p7O4Dz6Di4LrxHUu+Y9 9txW2Wrf4y90E0hV7i3zDTZfOS3nMh5Y2cM2vjSM= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-53240: xfrm: iptfs: fix use-after-free on first_skb in __input_process_payload Date: Thu, 25 Jun 2026 09:41:28 +0100 Message-ID: <2026062511-CVE-2026-53240-542b@gregkh> X-Mailer: git-send-email 2.54.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3009; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=lS7j0960Unqgqg63CelKRRt51HUZ9j1/0WIWi3FphOk=; b=owGbwMvMwCRo6H6F97bub03G02pJDFk2L7N5a7zk7sYzv3vS9jDOxVKbedaj4jOlto9+RX9ao 9IzISGnI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACbymoVhwaWSyB1fc3ovz+Iv Pbam478B47c1IQwLNuYqLolewfRIfQ5H3a6dpesWXWZbDQA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: xfrm: iptfs: fix use-after-free on first_skb in __input_process_payload __input_process_payload() stores first_skb into xtfs->ra_newskb under drop_lock when starting partial reassembly, then unlocks and breaks out of the processing loop. The post-loop check reads xtfs->ra_newskb without the lock to decide whether first_skb is still owned: if (first_skb && first_iplen && !defer && first_skb != xtfs->ra_newskb) Between spin_unlock and this read, a concurrent CPU running iptfs_reassem_cont() (or the drop_timer hrtimer) can complete reassembly, NULL xtfs->ra_newskb, and free the skb. The check then evaluates first_skb != NULL as true, and pskb_trim/ip_summed/consume_skb operate on the freed skb — a use-after-free in skbuff_head_cache. Replace the unlocked read with a local bool that records whether first_skb was handed to the reassembly state in the current call. The flag is set after the existing spin_unlock, before the break, using the pointer equality that is stable at that point (first_skb == skb iff first_skb was stored in ra_newskb). The Linux kernel CVE team has assigned CVE-2026-53240 to this issue. Affected and fixed versions =========================== Issue introduced in 6.14 with commit 3f3339885fb343b7b42d7c34717108ce07da24ae and fixed in 6.18.36 with commit 8d9a79fbf5172d9c4c0146057af2360913265a11 Issue introduced in 6.14 with commit 3f3339885fb343b7b42d7c34717108ce07da24ae and fixed in 7.0.13 with commit ff2ee35b6ce5fa8a8e24ea50b15733d5c8780198 Issue introduced in 6.14 with commit 3f3339885fb343b7b42d7c34717108ce07da24ae and fixed in 7.1 with commit eb48730bb827d1550401a5d391903f9d90b493c8 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-53240 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: net/xfrm/xfrm_iptfs.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/8d9a79fbf5172d9c4c0146057af2360913265a11 https://git.kernel.org/stable/c/ff2ee35b6ce5fa8a8e24ea50b15733d5c8780198 https://git.kernel.org/stable/c/eb48730bb827d1550401a5d391903f9d90b493c8