Kernel compromise via stale SMB directory pointer
Published Dec 8, 2025 · Updated Aug 5, 2026
Use-after-free in the SMB client of affected Linux kernels allows remote attackers controlling an SMB server to corrupt kernel memory. On a retry in smb2_query_info_compound(), the first attempt can free cfid, but replay leaves that stale pointer for later cleanup to dereference. A CIFS mount to a malicious or compromised server, or an unsigned session exposed to an on-path attacker, is required; exploitation can disclose kernel memory, crash the host, or enable kernel-level code execution.
Summary
What happened
Use-after-free in the SMB client of affected Linux kernels allows remote attackers controlling an SMB server to corrupt kernel memory. On a retry in smb2_query_info_compound(), the first attempt can free cfid, but replay leaves that stale pointer for later cleanup to dereference. A CIFS mount to a malicious or compromised server, or an unsigned session exposed to an on-path attacker, is required; exploitation can disclose kernel memory, crash the host, or enable kernel-level code execution.
The record
- CVE
- CVE-2025-40320
- Published
- Dec 8, 2025
- Updated
- Aug 5, 2026
- Vendor
- The Linux Kernel Organization
- Product
- Linux
- Classifications
- T1203
- Attack vector
- network
- Privileges
- unauthenticated
Timeline
How it unfolded
- Dec 8, 2025CVE publishedPublication date reported by the CVE source.
- Aug 5, 2026Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=433042a91f9373241307725b52de573933ffedbf <939c4e33005e2a56ea8fcedddf0da92df864bd3b
- Affected versionversion=4f1fffa2376922f3d1d506e49c0fd445b023a28e <327f89c21601ebb7889f8c97754b76f08ce95a0c
- Affected versionversion=4f1fffa2376922f3d1d506e49c0fd445b023a28e <5c76f9961c170552c1d07c830b5e145475151600
- Affected versionversion=4f1fffa2376922f3d1d506e49c0fd445b023a28e <b556c278d43f4707a9073ca74d55581b4f279806
- Affected versionversion=6.6.32 <6.6.117
- Affected versionversion=6.8
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
No public exploit references are available in this record.
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo