FreeBSD Fixes Kernel Use-After-Free in `TIOCNOTTY` Allowing Root Privilege Escalation
Attack Tradecraft · 2 sources · Updated 5mo ago · First seen Apr 21, 2026

The FreeBSD Project issued security advisory FreeBSD-SA-26:10.tty for CVE-2026-5398, a kernel use-after-free flaw in the TIOCNOTTY handler that affects all supported FreeBSD versions. The vulnerability occurs because TIOCNOTTY does not clear a back-pointer from the controlling terminal structure to the calling process session, leaving a dangling pointer after the process exits.
FreeBSD warned that a malicious unprivileged local process could exploit the bug to gain root privileges. The project released fixes across supported stable and release branches on 2026-04-21, said no workaround is available, and directed administrators to apply the updates and reboot affected systems.


