NFS2ROOT flaw exposes Linux NFS servers to remote root

NFS2ROOT flaw exposes Linux NFS servers to remote root

Add CyberWorldOpsto your preferred sources on Google
NFS2ROOT flaw exposes Linux NFS servers to remote root
Vulnerabilities

Illustrative image generated with AI

Linux servers running vulnerable versions of the kernel’s Network File System (NFS) server can be taken over remotely without a login, security firm OpenSec reports. The vulnerability, CVE-2026-99362, affects NFSv4.1 and NFSv4.2 services reachable on TCP port 2049; fixes are available, but administrators must check their distribution’s package status and reboot after updating.

OpenSec named the flaw NFS2ROOT and says it demonstrated an exploit that gives an attacker root privileges, providing full administrative control. File servers, network-attached storage appliances, build farms and Kubernetes storage nodes running the affected Linux service are among the systems administrators should check. Exploitation requires neither existing privileges nor user interaction.

BleepingComputer reported on November 27 that there were no reports of exploitation in the wild. OpenSec says its full exploit remains private, although it shared it with kernel maintainers and published a demonstration.

How an NFS request becomes root access

The flaw is a heap buffer overflow: the server writes beyond an allocated area of kernel memory. It sits in nfsd, the NFS server built into the Linux kernel, which handles network requests before authenticating the client.

NFSv4.1 sessions keep a cached reply for each request slot so that retries can receive the same response without repeating an operation. A client can negotiate a cache limit that leaves those reply buffers with zero bytes of usable space. A specially constructed request then causes the server to treat a SEQUENCE operation as successful and copy the entire reply into that undersized allocation.

The upstream kernel fix documents an 80-byte write. OpenSec says 61 bytes extend beyond the heap object, with 40 bytes controlled by the client. The correction checks that the reply fits before accepting the request slot; OpenSec also describes a companion correction that makes the encoder report when an operation cannot fit.

OpenSec’s exploit chains that overwrite with further NFS requests. It corrupts a neighboring slot’s bookkeeping, retrieves 3.8 KB of kernel memory and bypasses KASLR, a defense that randomizes kernel memory addresses. It then makes the kernel free a chosen object and fills the released memory with a forged callback—a function reference that the server later invokes.

Closing the connection triggers that callback and runs /bin/sh as root, OpenSec says. In its recorded demonstration, the command whoami; id; poweroff -f prints the root identity and then powers off the victim server.

Discovery and disclosure

The vulnerability dates to commit 47ee52986472, introduced in 2014 and shipped in Linux 3.16. OpenSec describes it as a 12-year-old flaw affecting long-term support, distribution and appliance kernels that have not received a fix.

ANSSI researcher Jérémy Jean independently found the bug and submitted a correction on August 17, 2026. The upstream record lists Jean as its author and NFSD maintainer Chuck Lever as the committer, dated October 4. It also credits testing by OpenSec’s Mayank Jangid and assistance from Codex:gpt-5.

OpenSec says its Antara automated analysis system identified the bug on September 21 and built the memory leak and root exploit without human intervention. That account of Antara’s capabilities is the company’s claim. OpenSec reported the vulnerability to the NFSD maintainers and the kernel security team on September 22, supplying the exploit and a patch that day. It dates publication of the CVE and fixes to November 20.

Check distribution packages before updating

Canonical rates the vulnerability critical, with a CVSS score of 9.8. Its tracker lists the linux packages for Ubuntu 26.10 at 7.3.0-12.13 and Ubuntu 26.04 LTS at 7.0.0-45.45 as vulnerable, with work in progress. Canonical recommends against cherry-picking individual patches.

OpenSec lists upstream fixes in Linux 6.12.117 for the 6.12 LTS branch, 6.18.61 for 6.18, 7.3.2 for 7.3, and 7.4-rc1 for mainline. Distribution kernels can carry backported fixes, so the kernel version alone does not establish exposure.

The Debian security tracker shows why package-level checks matter. It lists Bookworm’s linux versions 6.1.176-1 and 6.1.192-3 as vulnerable, while the separate linux-6.12 security package is fixed at 6.12.117-1~deb12u1. Trixie is fixed at 6.12.117-1, with its security package also fixed at 6.12.118-1. Forky’s 7.3.5-1 and Sid’s 7.3.6-1 are listed as fixed; Debian records 7.3.3-1 as the fixed version for unstable.

Administrators should check whether an unpatched kernel is running, nfsd is loaded, NFSv4.1 or NFSv4.2 is enabled, and an attacker can reach TCP port 2049. OpenSec suggests checking the running kernel with uname -r, the module with lsmod | grep -w nfsd, and enabled protocol versions with cat /proc/fs/nfsd/versions, looking for +4.1 or +4.2.

For detection, OpenSec says the exploit uses valid NFS requests and has no network signature. Potential signs include warnings from nfsd4_check_resp_size, which it says occur on successful and unsuccessful attempts; kernel fault reports containing nfsd4_*, svc_* or call_usermodehelper* frames; shells launched by kernel workers; and bursts of short NFSv4.1 sessions from one source.

Administrators should install their distribution’s kernel update covering CVE-2026-99362 and reboot. Until then, OpenSec recommends restricting TCP port 2049 to trusted clients or storage networks. Another temporary option is setting vers4.1=n and vers4.2=n under [nfsd] in /etc/nfs.conf, then restarting nfs-server; this disables parallel NFS and some NFSv4.2 features. Where NFS sharing is unnecessary, administrators can stop and disable the service.

Security dossiers

Read next

Sources

CVEs covered in this article

Back to home

Latest Cybersecurity News

All cybersecurity news →