Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-93221 Overview
CVE-2026-93221 is a race condition in the Linux kernel's NFS server (nfsd) subsystem. The flaw resides in nfsd4_end_grace(), where the grace_ended boolean in struct nfsd_net is checked and set without serialization. Two concurrent kernel contexts, the laundromat workqueue (nfs4_laundromat) and the NFSv4 RECLAIM_COMPLETE compound processing path, can both observe grace_ended == false, both set it to true, and both proceed into nfsd4_record_grace_done(). The downstream nfs4_release_reclaim() call then walks reclaim_str_hashtbl twice concurrently, corrupting list state and double-freeing every nfs4_client_reclaim entry.
Critical Impact
Concurrent execution of grace-done cleanup causes double-free and use-after-free conditions in NFSv4 server reclaim state, enabling kernel memory corruption on hosts running nfsd.
Affected Products
- Linux kernel NFS server (nfsd) subsystem
- Systems exporting NFSv4 shares with the legacy or cld client tracking operations
- Kernel versions prior to the fixes in commits 11a5fe42e181 and df5922fe09a8
Discovery Timeline
- 2026-09-24 - CVE-2026-93221 published to NVD
- 2026-09-25 - Last updated in NVD database
Technical Details for CVE-2026-93221
Vulnerability Analysis
The nfsd_net structure holds several boolean fields that are read and written from concurrent contexts without any locking. The grace period termination logic in nfsd4_end_grace() is the most impactful instance. It executes the pattern if (nn->grace_ended) return; nn->grace_ended = true; with no atomicity between the check and the set.
Two unrelated callers can enter this function simultaneously on different CPUs. The laundromat kworker reaches it through nfs4_laundromat(). The NFSv4 compound processing kthread reaches it through nfsd4_reclaim_complete() and inc_reclaim_complete(). Both callers can observe the field as false, both set it to true, and both invoke nfsd4_record_grace_done().
For tracking operations that drain reclaim_str_hashtbl, specifically legacy_tracking_ops via nfsd4_recdir_purge_old() and the cld v1+ operations via nfsd4_cld_grace_done(), the callback invokes nfs4_release_reclaim(). That function iterates every bucket without a lock, calling nfs4_remove_reclaim_record() (a list_del plus kfree) on each entry. A concurrent nfsd4_find_reclaim_client() traversing the same bucket reads freed memory.
Root Cause
The root cause is a Time-of-Check Time-of-Use (TOCTOU) race on an unserialized boolean field in struct nfsd_net. Plain C reads and writes against a bool provide no mutual exclusion across CPUs, allowing two threads to pass the guard and execute the one-shot cleanup twice.
Attack Vector
Triggering the race requires an NFSv4 client to send a RECLAIM_COMPLETE operation while the laundromat workqueue concurrently decides to end the grace period. The server must be running nfsd with reclaim tracking enabled. Successful exploitation produces list corruption and double-free of nfs4_client_reclaim objects in kernel heap memory, which can escalate to kernel memory corruption and potential privilege impact. The fix replaces the scattered booleans with a single unsigned long flags word and uses test_and_set_bit() for the grace-ended check, which is atomic on all architectures. See the upstream commit df5922fe09a8 and commit 11a5fe42e181 for the resolution.
Detection Methods for CVE-2026-93221
Indicators of Compromise
- Kernel oops or panic traces referencing nfs4_release_reclaim, nfs4_remove_reclaim_record, or nfsd4_find_reclaim_client
- list_del corruption warnings in dmesg originating from the nfsd subsystem
- Double-free or use-after-free KASAN splats involving nfs4_client_reclaim allocations
- Unexpected nfsd kthread crashes shortly after NFSv4 grace period expiry
Detection Strategies
- Enable KASAN on test and staging kernels running nfsd to surface use-after-free and double-free conditions during fuzzing or load tests
- Correlate nfsd crash dumps with NFSv4 client RECLAIM_COMPLETE traffic around grace period expiry
- Monitor kernel logs for list debugging warnings tied to the reclaim_str_hashtbl buckets
Monitoring Recommendations
- Forward kernel ring buffer and journald kernel facility events to a centralized log pipeline for pattern matching on nfsd stack traces
- Alert on unexpected restarts of the nfs-server systemd unit or recurring nfsd thread crashes
- Track NFSv4 grace period duration and RECLAIM_COMPLETE operation rates to identify timing windows that approximate the race
How to Mitigate CVE-2026-93221
Immediate Actions Required
- Apply the upstream kernel patches referenced in commits df5922fe09a8 and 11a5fe42e181, or install vendor kernel updates that incorporate them
- Inventory all Linux systems exporting NFSv4 shares and prioritize patching those with the highest client connection counts
- Schedule a reboot after kernel package installation to load the fixed nfsd module
Patch Information
The fix replaces the individual boolean fields in nfsd_net with a single unsigned long flags word and an enum nfsd_net_flag for bit positions. The grace_ended race is closed by using test_and_set_bit(), which is atomic on all architectures. The remaining flags (grace_end_forced, in_grace, somebody_reclaimed, track_reclaim_completes, nfsd_net_up, lockd_up) are converted to test_bit, set_bit, and clear_bit for consistency. Reference the kernel.org commit df5922fe09a8 and kernel.org commit 11a5fe42e181.
Workarounds
- Restrict NFSv4 client access to trusted networks using firewall rules on TCP/UDP port 2049 until patched kernels are deployed
- Where feasible, downgrade exports to NFSv3 which does not use the NFSv4 grace reclaim state machine
- Avoid frequent nfsd service restarts in production, since the grace period and client reclaim window is the race trigger
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

