CVE-2025-38321: smb: Log an error when close_all_cached_dirs fails
In the Linux kernel, the following vulnerability has been resolved:
smb: Log an error when close_all_cached_dirs fails
Under low-memory conditions, close_all_cached_dirs() can't move the
dentries to a separate list to dput() them once the locks are dropped.
This will result in a "Dentry still in use" error, so add an error
message that makes it clear this is what happened:
[ 495.281119] CIFS: VFS: \\otters.example.com\share Out of memory while dropping dentries
[ 495.281595] ------------[ cut here ]------------
[ 495.281887] BUG: Dentry ffff888115531138{i=78,n=/} still in use (2) [unmount of cifs cifs]
[ 495.282391] WARNING: CPU: 1 PID: 2329 at fs/dcache.c:1536 umount_check+0xc8/0xf0
Also, bail out of looping through all tcons as soon as a single
allocation fails, since we're already in trouble, and kmalloc() attempts
for subseqeuent tcons are likely to fail just like the first one did.
Security readout for executives and security teams
Plain-English summary
Under low-memory conditions, Linux’s SMB/CIFS client may fail to release cached directory entries while closing connections or unmounting a share, producing a kernel warning that entries remain in use. The supplied CVSS rates potential confidentiality, integrity, and availability impacts as high, but the source narrative only demonstrates the cleanup failure and warning.
Executive priority
Schedule expedited remediation for affected SMB client systems, especially multi-user servers or systems prone to memory pressure. CVSS 7.8 supports high priority, but the absence of KEV evidence and incomplete explanation of security impact do not support treating this as a confirmed active-exploitation emergency.
Technical view
An allocation failure in close_all_cached_dirs() can prevent dentries from being moved to a temporary list for dput() after locks are released. This leaves dentries referenced during CIFS unmount checks. The referenced resolution adds an explicit out-of-memory error and stops processing additional tree connections after the first allocation failure.
Likely exposure
Candidates are Linux systems running versions explicitly marked affected—6.13, 0, 6.6.95, 6.12.35, 6.15.4, and 6.16—that use SMB/CIFS client functionality. The version data is unusual and mixes affected and unaffected stable releases, so administrators should verify distribution backports rather than relying only on version strings.
Exploitation context
The bundle reports no KEV listing or evidence of active exploitation. The supplied vector describes local, low-complexity exploitation requiring low privileges and no user interaction. The technical narrative additionally requires memory pressure during SMB cached-directory cleanup, but does not establish reliable exploitation, remote triggering, or the claimed complete confidentiality, integrity, and availability impacts.
Researcher notes
The record is unusual: the described resolution primarily improves diagnostic logging and stops further allocation attempts, while the supplied CVSS asserts complete confidentiality, integrity, and availability impacts. The bundle does not explain that impact path. Validate CNA version metadata, patch semantics, and distribution backports before making exploitability claims.
Mitigation direction
Apply a vendor-supported kernel containing the referenced stable fix or an equivalent distribution backport.
Confirm the exact remediated build through Linux distribution or appliance-vendor guidance.
Prioritize affected systems that actively mount SMB/CIFS shares and face memory-pressure risk.
Maintain memory headroom on affected SMB clients until the appropriate kernel update is installed.
Validation and detection
Inventory kernel versions on systems using SMB/CIFS client mounts.
Check distribution package metadata for backports of the referenced upstream commits.
Review kernel logs for CIFS out-of-memory and “Dentry still in use” messages.
After updating, confirm systems booted into the remediated kernel build.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2025-38321 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
0ADP providers
5Source links
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.