UBUNTU-CVE-2026-98230: Use After Free
In the Linux kernel, the following vulnerability has been resolved: xfrm: use hlistdelinitrcu for statecache and statecacheinput Commit 14acf9652e56 ("xfrm: defensively unhash xfrmstate lists in xfrmstatedelete") converted bydst/bysrc/byseq/byspi from hlistdelrcu() to hlistdelinitrcu() so that a second xfrmstatedelete() on the same object becomes a no-op rather than a write through LISTPOISON pprev. It missed statecache and statecacheinput, which kept hlistdelrcu(): - hlistdelrcu() leaves pprev = LISTPOISON2 (non-NULL), so hlistunhashed() returns false. - hlistdelinitrcu() leaves pprev = NULL, so hlistunhashed() returns true. A second xfrmstatedelete() therefore enters hlistdel() on the already-deleted statecache/statecacheinput nodes and does WRITEONCE(pprev, next) through LISTPOISON2 — a write use-after-free once the slab is reused. The corruption can in turn cause a subsequent hlistforeachentryrcu traversal to follow a dangling next pointer, producing the read use-after-free reported in xfrminputstatelookup(). Switch statecache and statecacheinput to hlistdelinitrcu() to match the other four lists, closing the write use-after-free and, with it, the read use-after-free it spawns.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ubuntu/linux-hwe-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-42.42~24.04.1 - Upgrade
Upgrade
ubuntu/linux-riscv-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-42.42.1~24.04.1 - Upgrade
Upgrade
ubuntu/linuxto a version that resolves this vulnerability.Fixed in 7.0.0-42.42 - Upgrade
Upgrade
ubuntu/linux-awsto a version that resolves this vulnerability.Fixed in 7.0.0-1016.17 - Upgrade
Upgrade
ubuntu/linux-gcpto a version that resolves this vulnerability.Fixed in 7.0.0-1016.18 - Upgrade
Upgrade
ubuntu/linux-ibmto a version that resolves this vulnerability.Fixed in 7.0.0-1017.17 - Upgrade
Upgrade
ubuntu/linux-oem-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-1017.17 - Upgrade
Upgrade
ubuntu/linux-oracleto a version that resolves this vulnerability.Fixed in 7.0.0-1015.16 - Upgrade
Upgrade
ubuntu/linux-riscvto a version that resolves this vulnerability.Fixed in 7.0.0-42.42.1 - Configuration
Change state_cache and state_cache_input from hlist_del_rcu() to hlist_del_init_rcu() so repeated __xfrm_state_delete() calls become a no-op instead of writing through LIST_POISON2.
Linux kernel xfrm state_cache and state_cache_input deletion function = hlist_del_init_rcu()