Vulnerability NFS2ROOT: how to obtain root privileges on exposed Linux servers
A critical vulnerability in the Linux kernel, identified as CVE-2026-99362, allows attackers to gain root privileges on exposed NFS servers. The flaw, present since 2014, exploits a buffer overflow to execute commands with elevated privileges.
KEY TAKEAWAYS
- The CVE-2026-99362 vulnerability (CVSS 9.8) allows unauthorized root access on Linux NFS servers.
- It exploits a buffer overflow in the NFSv4.1/4.2 response caching mechanism.
- Upgrade to Linux 6.12.117, 6.18.61, 7.3.2 or 7.4-rc1 to mitigate the risk.
- Restrict access to TCP port 2049 and monitor logs for signs of exploitation.
Transcript
A critical vulnerability, known as NFS2ROOT, has been discovered in Linux NFS servers, allowing remote root access without authentication. The flaw, identified as CVE-2026-99362, has a CVSS score of 9.8 and dates back to 2014. It exploits a buffer overflow in the NFSv4.1 and NFSv4.2 response caching mechanism, enabling attackers to gain maximum privileges.
The vulnerability affects Linux kernels from version 3.16 onwards with NFSv4.1 or NFSv4.2 enabled. Exploitation requires access to TCP port 2049, even from internal networks. The fix checks buffer sizes before copying data. Users are advised to update to kernel versions 6.12.117, 6.18.61, 7.3.2, or 7.4-rc1.
The flaw was introduced in March 2014 and identified by Jérémy Jean of the French National Agency for the Security of Information Systems (ANSSI). OpenSec independently discovered the issue using its Antara system.
To verify exposure, run specific commands to check your system's configuration. Mitigation measures include limiting access to TCP port 2049, disabling NFSv4.1 and NFSv4.2, or completely disabling the NFS service if not needed.
Monitoring and detection of exploitation signals are crucial. OpenSec recommends monitoring system logs for specific alerts and unintentional crashes related to certain functions. Bursts of short NFSv4.1 sessions from the same IP address should also be investigated.
This vulnerability underscores the importance of robust identity management, zero trust architecture, and compliance with regulations like the NIS2 Directive and DORA Regulation. Organizations should consider implementing Managed Detection and Response (MDR) solutions and conducting regular security audits.
The discovery of NFS2ROOT highlights the growing importance of cybersecurity solutions, with the global market estimated at $266.9 billion in 2026. It also emphasizes the need for a supply chain security approach and the challenges of updating enterprise environments.