Port 2049 is the kind of port you open once for a file share, get working, and then stop thinking about. This week it turned out that the thing listening there has been accepting writes into kernel memory from strangers since 2014.
The bug is CVE-2026-99362, nicknamed NFS2ROOT by the team that published the research, OpenSec Intelligence. It is a heap out-of-bounds write in nfsd, the NFS server built into the Linux kernel. The Linux CNA scored it 9.8 with the vector AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H, and the CVE record was published on November 19, 2026. OpenSec’s write-up went out on November 25, and it reached oss-security on November 28.
I checked the CISA KEV feed before writing this: 1,808 entries, zero matches for this CVE. NVD still lists the record as “Received,” meaning no independent NVD analysis has been done yet and the 9.8 is the assigner’s number, not a second opinion. Nobody has reported exploitation in the wild as of November 26, the last date watchTowr put on that claim. Several write-ups say a public remote-root exploit already exists, but OpenSec says its own exploit stays private and describes only the steps.
So this is not a fire. It is a 12-year-old hole, in a service most of us expose on purpose, with a fix that is already in the tree.
🔓 How the write actually happens
NFSv4.1 introduced sessions, and sessions have slots. Each slot caches its last reply so that a retried request can be answered exactly once instead of twice. The client decides how large that cache is, using ca_maxresponsesize_cached in the CREATE_SESSION call.
The client negotiates the cached reply size down to NFSD_MIN_HDR_SEQ_SZ, the smallest value the protocol allows, so nfsd4_alloc_slot() hands every slot a zero-length sl_data[]. Next, nfsd4_sequence() shrinks the reply buffer to that limit, and it does so before it accepts the slot’s seqid.
Then the request tag does the rest. Size the COMPOUND tag so the narrowed buffer fills until it holds the SEQUENCE opcode but not the status word that follows. nfsd4_encode_operation() cannot fit the result, so it returns without ever running nfsd4_encode_sequence(). It also leaves op->status at nfs_ok, which means the server treats the COMPOUND as having succeeded.
The caching check in nfsd4_store_cache_entry() is supposed to refuse to cache a lone SEQUENCE that returned an error. It reads the status the operation reported. The operation reported success. So the cache path runs, the copy starts at offset zero, and it takes the whole reply, RPC header and COMPOUND header included, into a buffer with room for nothing.
The KASAN report in the commit message is the plain version: slab-out-of-bounds in read_bytes_from_xdr_buf, write of size 80. OpenSec’s breakdown is more useful for impact. 61 of those bytes land past the end of the heap object, 40 of them chosen by the client, on the neighboring kmalloc-96 object.
None of this requires a valid user. nfsd parses the request before it knows who you are, which is what “pre-auth” means here: not a bypass of a check, but code that runs before any check exists.
🧩 Twelve years in one commit
The bug came in with commit 47ee52986472, which shipped in Linux 3.16. Every kernel from there forward carries it: LTS, distribution and appliance kernels alike.
Two people found it. Jérémy Jean of ANSSI sent a fix upstream with a KASAN report, and the patch thread is dated August 17, 2026. OpenSec reported it to the NFSD maintainers and [email protected] on September 22 with a full remote-root exploit and a patch of its own. The CVE then published on November 19 with fixes attached.
There is a detail in that timeline worth sitting with. OpenSec’s harness, Antara, flagged the reply-cache path, scored it, and built the leak, the arbitrary free and the root shell end to end with no human in the loop. White-box tooling that escalates a memory safety bug into a working chain is not a curiosity anymore. It sets the clock on every bug of this shape, because the expensive part of exploitation was never the overflow. It was the chain.
The “vulnerable by default” claim in the headline coverage needs one qualifier, because it changes who has to act. The service has to be running nfsd and serving NFSv4.1 or 4.2 on a reachable tcp/2049. NFSv3 has no sessions, so it has no slots, so it does not reach this code. If you are running an old appliance locked to v3 with an authenticated export, you are not in this path. Modern clients negotiate 4.1 or higher without being asked, though, so “we never configured v4” is not the same statement as “we are not serving it.” Check what the daemon actually advertises rather than what’s in a config file someone wrote years ago.
🎯 What the chain looks like after the write
The overflow is step one of five. OpenSec describes the rest as ordinary NFS requests.
The write corrupts the neighboring slot’s bookkeeping. A replay request then returns 3.8 KB of kernel heap, and that leak carries the KASLR slide. A forged pointer makes the kernel free an object of the attacker’s choosing. That memory is refilled with a fake callback assembled from NFS client names. Then the attacker hangs up, nfsd calls the callback, and the kernel runs /bin/sh as root.
In their recording, the command is whoami; id; poweroff -f. The victim prints root, then uid=0(root), and switches itself off.
That sequence is the argument against scheduling this as a routine memory safety fix. KASLR bypass, arbitrary free, and a controlled callback amount to a general kernel compromise primitive on a file server, which is where the data lives.
🛠️ The patch list, and the part nobody patches
Upstream fixes are 6.12.117, 6.18.61, 7.3.2 and 7.4-rc1. The CVE record also lists backports in 5.10.275, 5.15.226, 6.1.193 and 6.6.163, which matters if you run an LTS branch that is not the newest one.
The fix is two commits, not one. 5d5a72e965c8 is Jean’s preflight check: confirm the fixed-size SEQUENCE result plus room for a following operation’s error status fits the negotiated limit before narrowing the buffer and consuming the slot seqid. 241848cc774e is the follow-up guard that makes the encoder set op->status when an operation’s header cannot be encoded. The reason to know both hashes is that a vendor backport can carry one and miss the other, and the second commit exists because the first alone still left a path where the encoder reports success.
Distribution status is moving. Debian’s security tracker shows linux fixed in bookworm security at 6.1.192-3 (DLA-4942-1), trixie at 6.12.117-1, forky at 7.3.5-1 and sid at 7.3.6-1, with linux-6.12 fixed at 6.12.117-1~deb12u1 under DLA-4927-1. The base bookworm package at 6.1.176-1 is still listed vulnerable, so the -security pocket is the one that counts.
Then there is everything that does not take a distribution kernel. NAS appliances. Kubernetes storage nodes running an NFS provisioner, where somebody built the node image two years ago and moved on. The fixed-version list above is a kernel list, not a product list. A NAS vendor has to rebase before you can act, and most will not publish a CVE page for you to search.
If you cannot patch today, you have two moves. Close the port:
nft add rule inet filter input tcp dport 2049 ip saddr != 10.20.0.0/16 drop
Or turn the vulnerable versions off in /etc/nfs.conf and restart nfs-server:
[nfsd]
vers4.1=n
vers4.2=n
That second one costs you pNFS and some 4.2 features. It is still cheaper than a root shell on the box holding your backups. And remember the reboot: patching the kernel package does nothing for the kernel that is currently running.
🔍 The only trace is a kernel warning
Here is the part that bothers me most. The attack is valid NFS. There is no malformed packet, no scanner signature, no shellcode in a payload. A sensor watching tcp/2049 sees a client negotiating a small cached reply size and sending well-formed requests.
What you get instead is local. Every attempt, successful or not, produces a kernel warning from nfsd4_check_resp_size, because the out-of-bounds copy has already happened by the time that check runs. Beyond that: oopses with nfsd4_*, svc_* or call_usermodehelper* frames, shells spawned by kernel workers on a file server, and bursts of short NFSv4.1 sessions from a single source.
So the place to look for attempts is dmesg and your kernel log shipping, for as long as you retained them. On a host where nobody reads kernel warnings, an attempt looks like a bad driver.
🧠 Final Thoughts
The interesting thing about NFS2ROOT is not the severity. We get a 9.8 in a network daemon every few weeks, and most of them are in userspace code that a package manager will replace before lunch. The interesting thing is that a twelve-year-old bug lives in the class of machine that is hardest to update and easiest to forget: the appliance in the rack that everyone treats as furniture, the storage node built from an image nobody owns.
So the checklist is short and unglamorous. Run uname -r on every host that exports NFS and compare it to the fix for its branch. Check whether tcp/2049 answers from anywhere it should not. If you are on a vendor kernel, open the ticket now, because your clock is set by their release engineering, not by yours. And grep your kernel logs for nfsd4_check_resp_size, just in case someone already tried.
Thanks for reading.