CVE-2026-52944: Linux ksmbd FSCTL Permission Bypass Vulnerability
CVE-2026-52944 is a permission-bypass flaw in the Linux kernel's ksmbd (SMB server) implementation. The FSCTL_SET_SPARSE operation, which controls whether a file is marked as sparse (a storage optimization technique), fails to verify user permissions before allowing the change. This means an unprivileged user could modify file attributes they shouldn't be able to touch—either because they're on a read-only share or because they lack the necessary write permissions on a writable share. The vulnerability requires local access to trigger but could lead to unauthorized file attribute modifications.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 5.5 MEDIUM · CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
- Weaknesses (CWE)
- —
- Affected products
- 6 configuration(s)
- Published / Modified
- 2026-06-24 / 2026-07-08
NVD description (verbatim)
In the Linux kernel, the following vulnerability has been resolved: ksmbd: fix FSCTL permission bypass by adding a permission check for FSCTL_SET_SPARSE FSCTL_SET_SPARSE in fsctl_set_sparse() modifies the file's sparse attribute and saves it through xattr without any permission checks. This exposes two issues: 1) A client on a read-only share can change the sparse attribute on files it opened, even though the share is read-only. Other FSCTL write operations already check test_tree_conn_flag(work->tcon, KSMBD_TREE_CONN_FLAG_WRITABLE), but FSCTL_SET_SPARSE does not. 2) Even on writable shares, clients without FILE_WRITE_DATA or FILE_WRITE_ATTRIBUTES access should not modify the sparse attribute. Similar handle-level checks exist in other functions but are missing here. Add both share-level writable check and per-handle access check. Use goto out on error to avoid leaking file references.
4 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
The vulnerability exists in the fsctl_set_sparse() function within ksmbd's FSCTL handling code. FSCTL_SET_SPARSE permits clients to set or unset the sparse file attribute via extended attributes (xattr) without enforcing two critical permission layers: (1) share-level write capability check (KSMBD_TREE_CONN_FLAG_WRITABLE), which other FSCTL write operations properly implement, and (2) handle-level access checks to verify FILE_WRITE_DATA or FILE_WRITE_ATTRIBUTES permissions on the file handle. The fix adds both the missing tree connection flag test and per-handle access validation, with proper error handling to prevent file reference leaks.
Business impact
Organizations running ksmbd-based SMB servers—common in NAS appliances, Linux-based storage solutions, and containerized environments—face unauthorized file attribute modification. While the sparse attribute itself doesn't expose file contents, it can be weaponized to trigger unexpected behavior in backup systems, storage deduplication tools, or compliance-sensitive workflows that rely on accurate file metadata. The impact is primarily data integrity and audit trail reliability rather than confidentiality breach.
Affected systems
The Linux kernel is affected. Organizations operating ksmbd as their SMB server implementation should inventory these systems, particularly in storage, NAS, and file-sharing appliances that expose SMB shares to local or network users. Standard desktop Linux systems with ksmbd enabled are less common but still at risk if SMB sharing is configured.
Exploitability
Exploitation requires local access (AV:L in the CVSS vector), meaning an attacker must already have a user account or shell access on the target system, or must be able to authenticate to an SMB share. The attack is trivial once that access is obtained—no special tools, race conditions, or user interaction are required. The barrier to exploitation is authentication/access, not technical complexity. Public exploitation code or proof-of-concept demonstrations are not yet known to be available.
Remediation
Apply patches once available from your Linux distribution or kernel maintainer that incorporate the permission checks described in the fix: tree connection write-flag validation and handle-level access permission verification. Verify the patch matches the commit that adds both the share-level and per-handle checks to fsctl_set_sparse(). For systems that cannot immediately patch, restrict SMB share access to trusted users and consider network-level segmentation to reduce the attack surface.
Patch guidance
Monitor your Linux distribution's security advisories and kernel update channels for patches addressing CVE-2026-52944. When patches are released, prioritize ksmbd systems that expose shares to untrusted or semi-trusted users. Verify patch application by confirming that fsctl_set_sparse() now includes both test_tree_conn_flag(work->tcon, KSMBD_TREE_CONN_FLAG_WRITABLE) and handle-level access checks before allowing sparse attribute modification. Test patch deployment in a staging environment to ensure SMB share functionality remains intact.
Detection guidance
Monitor system logs and audit trails for unusual FSCTL_SET_SPARSE calls on shared files, particularly from non-privileged users or from read-only share access contexts. If your system supports SMB operation logging, enable detailed FSCTL operation auditing. Watch for cases where file sparse attributes are modified without corresponding write operations or permission grants. Network-based detection is difficult without deep SMB inspection, so focus on endpoint logs and SMB server audit events.
Why prioritize this
Although the CVSS score is 5.5 (MEDIUM), prioritization should reflect the practical threat in your environment. If your organization relies on ksmbd for critical file sharing or storage appliances, prioritize patching higher because metadata integrity is essential for compliance and backup reliability. If ksmbd is rarely used or only in isolated test environments, deprioritize. The local-access requirement (AV:L) limits blast radius compared to network-exploitable flaws, but the trivial exploitability (AC:L, PR:L) means any authenticated user can trigger it.
Risk score, explained
The CVSS:3.1 score of 5.5 reflects that the vulnerability requires local or authenticated access (PR:L, AV:L), produces no confidentiality impact (C:N), no availability impact in the traditional sense (A:H refers to availability of the file attribute modification capability, not service disruption), and integrity is affected only in the narrow sense of file attributes. The score appropriately penalizes the ease of exploitation (AC:L) but credits the access boundary. Risk in your environment may be higher or lower depending on how widely ksmbd is deployed and how much you rely on accurate file metadata for operations, compliance, or audit purposes.
Frequently asked questions
Can an attacker read or delete files using this vulnerability?
No. This vulnerability permits modification of the sparse file attribute only. It does not grant unauthorized read, write, or delete access to file contents. However, if sparse attribute metadata is relied upon for storage optimization, deduplication, or compliance workflows, altering it could cause cascading issues.
Does this affect standard Linux distributions on desktop or server by default?
Most standard Linux distributions do not enable or expose ksmbd by default. Ksmbd is typically found in NAS appliances, specialized storage solutions, and systems explicitly configured to provide SMB file sharing. Check if ksmbd is running on your systems before assuming risk.
What is the sparse file attribute and why does it matter?
The sparse file attribute indicates that a file is sparse, meaning it contains large blocks of empty or null data that can be stored more efficiently. If an attacker modifies this attribute without authorization, they can disrupt storage optimization, trigger unexpected behavior in backup tools, or corrupt audit trails that depend on accurate metadata.
Can this be exploited remotely?
Exploitation requires prior access to the system or authentication to an SMB share, so it is not remotely exploitable without an existing account or connection. An attacker cannot directly compromise a system from the internet using only this vulnerability; they must already have local or SMB access.
This analysis is based on the published CVE description and CVSS metrics as of the provided data date. Patch versions, affected kernel releases, and vendor-specific advisory details are not provided in the source data; verify against official Linux distribution security advisories and kernel.org for authoritative patch information. No exploit code or weaponized proof-of-concept instructions are provided. Organizations should conduct risk assessment in their specific environment, considering their use of ksmbd and the sensitivity of file metadata integrity in their workflows. This vulnerability is not currently listed in the CISA Known Exploited Vulnerabilities (KEV) catalog as of the data provided. Source: NVD (public-domain), retrieved 2026-07-30. Analysis generated by SEC.co (claude-haiku-4-5).
Affected vendors
Related vulnerabilities
- CVE-2025-71313MEDIUMLinux Kernel PCI Endpoint NULL Pointer Dereference
- CVE-2025-71314MEDIUMLinux Panthor GPU Driver Denial of Service via Cache Flush Timeout
- CVE-2025-71315MEDIUMLinux Kernel vkms DRM Vblank Timer Denial of Service
- CVE-2026-0268MEDIUMPrisma Access Agent Linux VPN Bypass Vulnerability
- CVE-2026-10004MEDIUMChrome UI Spoofing Vulnerability – Password Dialog Hijacking
- CVE-2026-10018MEDIUMInteger Overflow in Chrome ANGLE GPU Graphics Layer
- CVE-2026-10912MEDIUMChrome Extension Same-Origin Policy Bypass (CVSS 6.5)
- CVE-2026-10916MEDIUMChrome DevTools UXSS Vulnerability