ZeroHour

CVE-2026-89658

large

Use-After-Free in Linux Kernel NFSD NFSv4.0 Revoked-State Cleanup

CVSS 3.1
9.8 critical
EPSS
Published
()
Modified
AI analysis

The Linux kernel's NFS server daemon (NFSD) contains a use-after-free in NFSv4.0 revoked-state cleanup: nfs40_clean_admin_revoked() takes a stateid reference but does not pin the owning client, so after dropping the client lock the client can be freed while nfsd4_drop_revoked_stid() still dereferences it. The race is triggered when the periodic laundromat sweep runs concurrently with a force_expire_client() operation initiated by an administrator writing to the nfsd clients/ctl control file, with attacker-controlled client activity influencing state churn and timing. Successful exploitation corrupts kernel memory on the NFS server, which in the worst case yields kernel-level code execution, though the CVSS 9.8 rating overstates practical exploitability since a tight race must be won and admin-triggered expiry is involved. Any system running the kernel's nfsd with NFSv4.0 exports and revoked-state reclamation is affected; the fix pins the client with cl_rpc_users or skips already-expiring clients. No public proof of concept is known and the flaw is not in CISA's KEV catalog.

What to do: Patch to a kernel release containing the nfs40_clean_admin_revoked() fix once your distribution ships it, prioritizing hosts running nfsd with NFSv4.0 exports. Until then, firewall TCP/2049 to trusted clients only and scan your perimeter for exposed NFS. As an operational mitigation, avoid writing to the nfsd clients/ctl control file (force-expiring clients) during periods of heavy client churn, since that is the racing trigger.

Affected
Linux (kernel.org) Linux kernel (NFSD / nfsd4 NFSv4.0 revoked-state handling)
Estimated exposure
largeorder of 10,000s of internet-exposed NFS servers, plus a much larger unmeasured population of internal enterprise NFS servers — Public internet scans (e.g., Shodan) consistently show tens of thousands of hosts with TCP/2049 open, while NFS is predominantly deployed on internal enterprise storage networks, so the truly exposed population is dominated by uncounted…

Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.

Description

In the Linux kernel, the following vulnerability has been resolved: NFSD: Prevent client use-after-free during NFSv4.0 revoked-state cleanup nfs40_clean_admin_revoked() takes a stateid reference under clp->cl_lock, drops nn->client_lock, and calls nfsd4_drop_revoked_stid(), which dereferences the stateid's client through s->sc_client->cl_lock. The stateid reference does not pin the client, so a teardown racing the dropped lock can free the client while nfsd4_drop_revoked_stid() is still using it. This cleanup runs from the laundromat, so a periodic sweep can race force_expire_client() driven by a write to the clients/ /ctl file. Skip a client that is already expiring and otherwise pin it with cl_rpc_users under client_lock before dropping the lock, matching nfsd4_revoke_states().

Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

In the news

No ingested article mentions this CVE yet.