CVE-2026-98169: smb: client: fix potential OOB read in smb3_enum_snapshots()

Published Oct 6, 2026
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

smb: client: fix potential OOB read in smb3enumsnapshots()

If snapshotarraysize is smaller than GMTTOKENSIZE, smb3enumsnapshots() sets retdatalen to sizeof(struct smbsnapshotarray) without verifying the actual length of the server's reply.

Because SMB2ioctl() places no lower bound on the server-supplied OutputCount and allocates retbuf to exactly that length, a short reply results in retdatalen exceeding the size of retbuf. The subsequent copytouser() then reads past the end of retbuf, leaking adjacent slab memory to userspace. The subsequent clamp check is ineffective as it only reduces retdatalen.

Fix this by rejecting replies shorter than sizeof(struct smbsnapshotarray) with -EIO. Note that the bound is set to the 12-byte struct size rather than the 16-byte MINSNAPSHOTARRAYSIZE defined in MS-SMB2 3.3.5.15.1, because 12 bytes is exactly what copytouser() attempts to read.

Affected Software

1 affected component
Linux Linux kernel

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Compensating control

    In smb3_enum_snapshots(), reject server replies shorter than sizeof(struct smb_snapshot_array) with -EIO before copying data to userspace.

Event History

Oct 6, 2026
CVE Published
via MITRE·08:44 AM
Data Sourced
via MITRE·08:44 AM
DescriptionSeverity
Data Sourced
via NVD·09:17 AM
DescriptionSeverity
Oct 7, 2026
Data Sourced
via Microsoft·08:07 AM
DescriptionSeverityWeakness

Frequently Asked Questions

1

What attacker-controlled condition is required to trigger the out-of-bounds read?

An SMB server must return a snapshot enumeration IOCTL reply whose OutputCount is shorter than sizeof(struct smb_snapshot_array). The vulnerable client then can copy more data to userspace than was allocated for the server reply.

2

Who is exposed to this issue?

Linux systems acting as SMB clients are exposed when they enumerate SMB3 snapshots against a server that supplies a malformed short response. The issue leaks adjacent kernel slab memory to local userspace through the client operation.

3

What does the fix do?

The fix rejects snapshot enumeration replies shorter than sizeof(struct smb_snapshot_array) with -EIO. This prevents copy_to_user() from reading beyond the allocated response buffer.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203