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

FreeBSD -- Stack overflow via select() file descriptor set overflow

Affected packages
15.0 <= FreeBSD < 15.0_7
14.4 <= FreeBSD < 14.4_3
14.3 <= FreeBSD < 14.3_12
13.5 <= FreeBSD < 13.5_13

Details

VuXML ID 892fabf5-4435-11f1-bb07-bc241121aa0a
Discovery 2026-04-29
Entry 2026-04-30

Problem Description:

When exchanging data over a socket, libnv uses select(2) to wait for data to arrive. However, it does not verify whether the provided socket descriptor fits in select(2)'s file descriptor set size limit of FD_SETSIZE (1024).

Impact:

An attacker who is able to force a libnv application to allocate large file descriptors, e.g., by opening many descriptors and executing a program which is not careful to close them upon startup, can trigger stack corruption. If the target application is setuid-root, then this could be used to elevate local privileges.

References

CVE Name CVE-2026-39457
FreeBSD Advisory SA-26:16.libnv