CVE-2026-31432
Received Received - Intake
Out-of-Bounds Write in Linux ksmbd QUERY_INFO Handling

Publication date: 2026-04-22

Last updated on: 2026-04-27

Assigner: kernel.org

Description
In the Linux kernel, the following vulnerability has been resolved: ksmbd: fix OOB write in QUERY_INFO for compound requests When a compound request such as READ + QUERY_INFO(Security) is received, and the first command (READ) consumes most of the response buffer, ksmbd could write beyond the allocated buffer while building a security descriptor. The root cause was that smb2_get_info_sec() checked buffer space using ppntsd_size from xattr, while build_sec_desc() often synthesized a significantly larger descriptor from POSIX ACLs. This patch introduces smb_acl_sec_desc_scratch_len() to accurately compute the final descriptor size beforehand, performs proper buffer checking with smb2_calc_max_out_buf_len(), and uses exact-sized allocation + iov pinning.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-04-22
Last Modified
2026-04-27
Generated
2026-05-07
AI Q&A
2026-04-22
EPSS Evaluated
2026-05-05
NVD
EUVD
Affected Vendors & Products
Showing 2 associated CPEs
Vendor Product Version / Range
linux_kernel ksmbd *
linux kernel *
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-UNKNOWN
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?

This vulnerability exists in the Linux kernel's ksmbd component, specifically in handling compound requests like READ + QUERY_INFO(Security). When the first command (READ) uses most of the response buffer, ksmbd may write beyond the allocated buffer while constructing a security descriptor.

The root cause is that the function smb2_get_info_sec() checked buffer space based on a size from extended attributes (ppntsd_size), but the actual security descriptor built by build_sec_desc() could be much larger due to POSIX ACLs. This mismatch led to out-of-bounds writes.

The fix involved accurately computing the final descriptor size before allocation, performing proper buffer size checks, and using exact-sized allocation with iov pinning to prevent writing beyond the buffer.


How can this vulnerability impact me? :

This vulnerability can cause out-of-bounds memory writes in the ksmbd service of the Linux kernel when processing certain compound SMB requests. Such memory corruption can lead to system instability, crashes, or potentially allow an attacker to execute arbitrary code or escalate privileges.


Ask Our AI Assistant
Need more information? Ask your question to get an AI reply (Powered by our expertise)
0/70
EPSS Chart