FreeBSD VuXML: Documenting security issues in FreeBSD and the FreeBSD Ports Collection

FreeBSD -- Use-after-free in kqueue copy-on-fork

Affected packages
15.1 <= FreeBSD-kernel < 15.1_2

Details

VuXML ID a4e4a74c-8bb7-11f1-a6ab-bc241121aa0a
Discovery 2026-07-29
Entry 2026-07-30

Problem Description:

While the kernel was copying knotes during fork, a knote with a timer-based filter could fire and be enqueued on the kqueue's active list before the copy was complete. The copy routine did not account for this and could enqueue the new knote a second time, corrupting the active list. In addition, the copy routine did not hold the appropriate locks while reading knote state, allowing further races.

Impact:

An unprivileged local user can trigger a use-after-free in the kernel, potentially leading to privilege escalation.

References

CVE Name CVE-2026-58083
FreeBSD Advisory SA-26:50.kqueue