CVE-2026-80758: futex: Avoid private hash use-after-free on final put
In the Linux kernel, the following vulnerability has been resolved:
futex: Avoid private hash use-after-free on final put
futexprivatehashput() drops the reference to fph before evaluating fph->mm for wakeupvar(). futexrefput() enables preemption again before returning. If that put drops the final reference and the task is preempted, another task can pivot to the replacement hash and free the old hash after an RCU grace period. The first task then reads fph->mm from the freed allocation when it resumes.
KASAN reports a slab-use-after-free in futexprivatehashput(), with the read at offset 24 in a freed kmalloc-512 allocation. The allocation and free stacks point to futexhashallocate() and the RCU free path, respectively.
Load the mm pointer while the fph reference is still held and pass the saved value to wakeupvar(). wakeupvar() uses the pointer as a waitqueue key and does not dereference the mm through it.
Affected Software
Event History
Frequently Asked Questions
What conditions are needed to trigger the race?
The final reference to a private futex hash must be dropped, the task must be preempted after references are released, and another task must switch to a replacement hash and free the old hash after an RCU grace period before the first task resumes.
How might an affected system present during testing?
KASAN can report a slab use-after-free in futex_private_hash_put(), involving a read at offset 24 of a freed kmalloc-512 allocation. The relevant allocation and free paths point to futex_hash_allocate() and the RCU free path.