{"id":"CVE-2026-53240","aliases":["CVE-2026-53240"],"related":[],"kind":"vulnerability","state":"published","title":"xfrm: iptfs: fix use-after-free on first_skb in __input_process_payload","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nxfrm: iptfs: fix use-after-free on first_skb in __input_process_payload\n\n__input_process_payload() stores first_skb into xtfs->ra_newskb under\ndrop_lock when starting partial reassembly, then unlocks and breaks out\nof the processing loop. The post-loop check reads xtfs->ra_newskb\nwithout the lock to decide whether first_skb is still owned:\n\n    if (first_skb && first_iplen && !defer && first_skb != xtfs->ra_newskb)\n\nBetween spin_unlock and this read, a concurrent CPU running\niptfs_reassem_cont() (or the drop_timer hrtimer) can complete\nreassembly, NULL xtfs->ra_newskb, and free the skb. The check then\nevaluates first_skb != NULL as true, and pskb_trim/ip_summed/consume_skb\noperate on the freed skb — a use-after-free in skbuff_head_cache.\n\nReplace the unlocked read with a local bool that records whether\nfirst_skb was handed to the reassembly state in the current call. The\nflag is set after the existing spin_unlock, before the break, using the\npointer equality that is stable at that point (first_skb == skb iff\nfirst_skb was stored in ra_newskb).","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nxfrm: iptfs: fix use-after-free on first_skb in __input_process_payload\n\n__input_process_payload() stores first_skb into xtfs->ra_newskb under\ndrop_lock when starting partial reassembly, then unlocks and breaks out\nof the processing loop. The post-loop check reads xtfs->ra_newskb\nwithout the lock to decide whether first_skb is still owned:\n\n    if (first_skb && first_iplen && !defer && first_skb != xtfs->ra_newskb)\n\nBetween spin_unlock and this read, a concurrent CPU running\niptfs_reassem_cont() (or the drop_timer hrtimer) can complete\nreassembly, NULL xtfs->ra_newskb, and free the skb. The check then\nevaluates first_skb != NULL as true, and pskb_trim/ip_summed/consume_skb\noperate on the freed skb — a use-after-free in skbuff_head_cache.\n\nReplace the unlocked read with a local bool that records whether\nfirst_skb was handed to the reassembly state in the current call. The\nflag is set after the existing spin_unlock, before the break, using the\npointer equality that is stable at that point (first_skb == skb iff\nfirst_skb was stored in ra_newskb).","source":"cvelist"}],"published":"2026-06-25T08:39:35.809Z","modified":"2026-08-05T12:34:26.772Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"}],"cwes":["CWE-416"],"affected":[{"ranges":[{"type":"git","introduced":"3f3339885fb343b7b42d7c34717108ce07da24ae","fixed":"8d9a79fbf5172d9c4c0146057af2360913265a11","status":"affected"},{"type":"git","introduced":"3f3339885fb343b7b42d7c34717108ce07da24ae","fixed":"ff2ee35b6ce5fa8a8e24ea50b15733d5c8780198","status":"affected"},{"type":"git","introduced":"3f3339885fb343b7b42d7c34717108ce07da24ae","fixed":"eb48730bb827d1550401a5d391903f9d90b493c8","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"6.14","status":"affected"},{"type":"semver","introduced":"0","fixed":"6.14","status":"unaffected"},{"type":"semver","introduced":"6.18.36","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"7.0.13","lastAffected":"7.0.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.1","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"6.14","fixed":"6.18.36"},{"status":"affected","introduced":"6.19","fixed":"7.0.13"},{"status":"affected","version":"7.1"},{"status":"affected","version":"7.1"},{"status":"affected","version":"7.1"},{"status":"affected","version":"7.1"},{"status":"affected","version":"7.1"},{"status":"affected","version":"7.1"},{"status":"affected","version":"7.1"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/8d9a79fbf5172d9c4c0146057af2360913265a11","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/ff2ee35b6ce5fa8a8e24ea50b15733d5c8780198","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/eb48730bb827d1550401a5d391903f9d90b493c8","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-53240","url":"https://www.cve.org/CVERecord?id=CVE-2026-53240","licence":"CVE Terms of Use","modified":"2026-08-05T12:34:26.772Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-53240","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-53240","licence":"Public domain","modified":"2026-07-08T13:05:31.967Z"}],"updatedAt":"2026-11-25T22:59:26.328Z","epss":{"score":0.00565,"percentile":0.40739,"date":"2026-11-30T12:00:22.000Z"}}