Critical NFS2ROOT Linux Kernel Flaw Enables Remote Root Access on Unpatched Servers

A critical vulnerability in the Linux kernel's Network File System (NFS) server, tracked as CVE-2026-99362 and dubbed NFS2ROOT by OpenSec, allows remote attackers to gain root privileges on vulnerable systems. Discovered by ANSSI researcher Jérémie Jean, the flaw is a heap buffer overflow in the Linux NFS server (nfsd) that has existed since kernel version 3.16, released in March 2014. It affects systems running kernels older than 6.12.117, 6.18.61, 7.3.2, or 7.4-rc1 when nfsd (v4.1 or 4.2) is loaded and TCP port 2049 is reachable over the Internet.

Attackers exploit the flaw by sending maliciously crafted requests that cause the NFS server to write data beyond an allocated memory buffer. This lets them read kernel memory, bypass KASLR protections, and place a callback that executes a command in a released memory area. When the attacker closes the NFS connection, the kernel runs the embedded command with root privileges, giving the attacker full control of the unpatched server. The low-complexity attacks require no user interaction and no prior authentication.

Although there are no reports of exploitation in the wild, security teams should apply the latest kernel updates immediately and reboot to ensure the patched kernel is running. Admins who cannot patch right away should restrict access to TCP port 2049 to trusted clients, or stop and disable the nfs-server service in /etc/nfs.conf if NFS sharing is not needed. OpenSec warns that port 2049 sits open on file servers, NAS appliances, build farms, and Kubernetes storage nodes, urging administrators to patch every host since kernel hardening does not remove the overflow.

Read More at the original source →