Skip to main content
Vulnerability Database/CVE-2026-97558

CVE-2026-97558: Linux Kernel Privilege Escalation Vulnerability

CVE-2026-97558 is a privilege escalation vulnerability in the Linux kernel SMB client that causes resource leaks through improper reference handling in deferred close operations. This article covers technical details, impact assessment, and mitigation strategies.

Published:

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-97558 Overview

CVE-2026-97558 is a reference count leak in the Linux kernel SMB (Server Message Block) client affecting the deferred close code path. The flaw lives in cifs_close() and the smb2_deferred_work_close() callback, where the cifsFileInfo reference is handed off to queued work without verifying that the work was actually queued. When queue_delayed_work() fails because the callback is mid-execution, the closing file's reference is never released. The pinned cifsFileInfo structure then leaks its associated tlink, dentry, and server handle. The issue was identified by an in-house static analysis tool and resolved upstream.

Critical Impact

Repeated open/close cycles on CIFS-mounted shares can exhaust kernel memory and pin SMB session state, leading to resource starvation on long-running systems.

Affected Products

  • Linux kernel SMB/CIFS client (fs/smb/client)
  • Systems mounting remote shares over SMB2/SMB3
  • Distributions tracking upstream stable kernel branches patched by commits 5520e89, a676771, and ea93759

Discovery Timeline

  • 2026-09-25 - CVE-2026-97558 published to NVD
  • 2026-09-25 - Last updated in NVD database

Technical Details for CVE-2026-97558

Vulnerability Analysis

The Linux CIFS client defers close operations to a workqueue to improve performance when files are reopened quickly. cifs_close() transfers ownership of the cifsFileInfo reference belonging to the closing struct file to the queued work item. Each run of smb2_deferred_work_close() is expected to drop one such reference.

The deferred_close_scheduled flag can briefly report false while work is still pending. The workqueue clears the PENDING bit when a callback begins executing, but the callback itself only clears deferred_close_scheduled later, under deferred_lock. A close occurring in that interval requeues the running work, and the callback then clears the flag, leaving a requeued work item pending without the flag set.

A subsequent cifs_open() can reuse the handle. The next cifs_close() reaches the same branch, calls queue_delayed_work(), and the queue call fails because the work is already pending. The function returns without releasing the closing file's reference. The reference count on cifsFileInfo remains elevated, and its tlink, dentry, and server handle are never freed.

Root Cause

The root cause is a missing return-value check on queue_delayed_work() inside the deferred close path. The code assumed the reference hand-off always succeeded. The fix inspects the return value and only transfers ownership when the work was actually queued. Otherwise it falls back to _cifsFileInfo_put(), mirroring the behavior of the adjacent mod_delayed_work() branch that already owns its reference.

Attack Vector

The flaw requires local file I/O against a CIFS-mounted share. A workload that rapidly opens and closes the same file during the window when a deferred close callback is executing can trigger the leak. Repeated triggering accumulates leaked cifsFileInfo structures, dentries, and server handles. The result is kernel memory exhaustion and persistent SMB session state that cannot be released. No authentication beyond normal share access is required, and the attack vector is primarily local to processes using the affected mount.

Detection Methods for CVE-2026-97558

Indicators of Compromise

  • Steady growth of cifsFileInfo allocations visible in /proc/slabinfo on hosts with active CIFS mounts
  • Persistent SMB sessions and tree connections in /proc/fs/cifs/DebugData that do not release after client processes exit
  • Rising kernel slab memory on systems that perform frequent open/close cycles against SMB shares

Detection Strategies

  • Monitor kernel slab usage for the cifs_file_info cache and alert on sustained upward trends uncorrelated with active workloads
  • Compare the running kernel version against the fixed commits 5520e89a5a4f, a676771290, and ea93759d6c27 to confirm patch status
  • Audit mounted filesystems for cifs or smb3 entries and correlate with workloads performing high-frequency file opens

Monitoring Recommendations

  • Collect /proc/meminfo and slab statistics on CIFS-connected hosts to detect gradual memory pressure
  • Track CIFS debug counters exposed under /proc/fs/cifs/Stats for anomalous handle retention
  • Enable kernel log collection in centralized logging to capture CIFS reconnection warnings tied to leaked session state

How to Mitigate CVE-2026-97558

Immediate Actions Required

  • Apply the stable kernel update containing commits 5520e89a5a4f834bced64cf2ac927001cc513a40, a6767712902beb0f53238be485971c9a83ea1079, and ea93759d6c2789924f4e557aed5be532207715ea
  • Inventory hosts using CIFS/SMB mounts and prioritize long-running servers that cannot be rebooted frequently
  • Reboot systems after patch installation to clear any already-leaked cifsFileInfo references

Patch Information

The fix is upstream in the Linux kernel stable tree. Reference the patches at Kernel Git Commit 5520e89, Kernel Git Commit a676771, and Kernel Git Commit ea93759. The patch adds a return-value check on queue_delayed_work() and routes the reference release through _cifsFileInfo_put() when queueing fails.

Workarounds

  • Reduce reliance on deferred close by mounting with nobrl or tuning closetimeo where supported to shorten the window for the race
  • Schedule periodic restarts of workloads that repeatedly open and close files on CIFS shares until the patched kernel is deployed
  • Where possible, migrate affected workloads to local or NFS storage until kernels are updated
bash
# Verify running kernel does not contain the vulnerable code path
uname -r

# Inspect active CIFS sessions and open handles
cat /proc/fs/cifs/DebugData

# Observe cifs_file_info slab allocations over time
grep cifs_file_info /proc/slabinfo

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

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.