Skip to main content
Menu
CVEs

Linux kernel out-of-bounds read leaks memory in CIFS directory search

CVE-2026-99427Published November 19, 2026, updated

Exploited
No known exploitation
Fix
Fixed in 2.6.26, 2.6.27, 2.6.28
Who is exposed
Not reported

Summary

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

smb: client: fix OOB last_entry pointer from unbounded LastNameOffset

CIFSFindFirst() and CIFSFindNext() locate the last entry of a TRANS2_FIND_FIRST2 or TRANS2_FIND_NEXT2 response by adding the LastNameOffset of the response parameters to the start of the data area, and store the result in psrch_inf->last_entry. MS-CIFS 2.2.6.2.2 defines that offset as the offset of the entry's file name; the client follows the reading of NT and Samba servers, which point it at the entry. LastNameOffset is only checked against CIFSMaxBufSize, which says nothing about the response actually received: validate_t2() lets the data area start up to 1024 bytes into the buffer, and SendReceive() copies at most CIFSMaxBufSize + MAX_CIFS_HDR_SIZE bytes of a response, 16468 by default, into a cifs_request allocation of CIFSMaxBufSize + MAX_SMB2_HDR_SIZE bytes, 16588 by default. The pointer itself can therefore be placed anywhere from the end of the received data to 820 bytes past the end of the allocation.

The read through that pointer is far larger than its displacement. find_cifs_entry() hands last_entry to cifs_save_resume_key() after every FindNext and after the FindFirst of a search rewind, and cifs_fill_dirent() takes the length of the name from the entry itself: a __le32 FileNameLength for most levels, a __u8 for SMB_FIND_FILE_INFO_STANDARD, and for SMB_FIND_FILE_UNIX the result of a scan for the terminating NUL over up to PATH_MAX + 1 UTF-16 units. The name is recorded as the resume name of the search, and the next CIFSFindNext() rejects only a recorded length of PATH_MAX or more before copying the name into the ResumeFileName of its request and sending it with the resume key taken from the same entry: up to 4 KiB of memory from past the end of the allocation leaks to the server, and for SMB_FIND_FILE_UNIX the NUL scan runs about twice as far before the length is even known. The entry does not have to lie outside the response for that either: a maximal response ends about 120 bytes before the end of the allocation, so an entry in its last bytes with a name just under PATH_MAX has nearly all of that name copied from past the allocation.

It needs nothing unusual from the client: a FindNext response that reports no entries and does not end the search makes find_cifs_entry() send the next FindNext at once, carrying whatever was parsed at LastNameOffset, and a search rewind can do the same after its FindFirst. SMB1 is not negotiated by default: this takes a malicious or compromised server, a mount of it with an explicit vers=1.0, which CONFIG_CIFS_ALLOW_INSECURE_LEGACY (default y) permits, and a directory listing on that mount.

With KASAN enabled, a response that places the last entry past the buffer, with a large DataOffset and a LastNameOffset near the end of its range, gives:

================================================================== BUG: KASAN: slab-out-of-bounds in cifs_save_resume_key.isra.0+0x7aa/0x7f0 Read of size 4 at addr ffff88807b55c33b by task ls/83

CPU: 1 UID: 0 PID: 83 Comm: ls Not tainted 7.3.0-rc4-00457-gf14572c203d5 #69 PREEMPT(lazy) Call Trace: <TASK> kasan_report+0xdf/0x1a0 cifs_save_resume_key.isra.0+0x7aa/0x7f0 cifs_readdir+0x1ed6/0x29c0 iterate_dir+0x1c0/0x570 __x64_sys_getdents64+0x133/0x270 do_syscall_64+0x109/0x5d0 entry_SYSCALL_64_after_hwframe+0x77/0x7f </TASK>

Allocated by task 83 on cpu 0 at 19.317556s: cifs_buf_get+0x36/0x90 smb_init+0x4f/0x110 CIFSFindNext+0xf7/0x14c0 cifs_readdir+0xf51/0x29c0

The buggy address belongs to the object at ffff88807b558000 which belongs to the cache cifs_request of size 16588 The buggy address is located 623 bytes to the right of allocated 16588-byte region [ffff88807b558000, ffff88807b55c0cc) ==================================================================

The four bytes read there are the FileNameLength of the entry, which cifs_fill_dirent() tak ---truncated---

What to do

Upgrade to a fixed version: 2.6.26, 2.6.27, 2.6.28.

Check your systems with an agent

Paste this into a coding or ops agent. It checks your systems read-only and reports a table per asset.

Check whether my systems are affected by CVE-2026-99427 (smb: client: fix OOB last_entry pointer from unbounded LastNameOffset), using the cve.now data below.

Rules: work read-only. Do not run exploit code, proof-of-concept scripts or scanners that send attack payloads, and do not change any configuration, package, image or deployment. Report findings only.

What cve.now has for CVE-2026-99427 (entry last updated 2026-11-19):
Affected:
- Linux Linux: from 2.6.25.19, fixed in 2.6.26; from 2.6.26.7, fixed in 2.6.27; from 2.6.27.2, fixed in 2.6.28
- Linux Linux: versions 2.6.28
Fixed versions: 2.6.26, 2.6.27, 2.6.28.
Setup: unknown whether the bug needs a non-default feature or setting. Check the advisory.
CISA KEV: CVE-2026-99427 is not listed as of cve.now's last read.
This KEV status is for CVE-2026-99427 only. If you also check another CVE, look up its own KEV status; never assume it from this one.

How to check:
- Installed software: check what is actually running, not what a repo declares. Read the version from each host, container image and Kubernetes node (the binary's version output, the OS package database, image layers), and check whether the conditions above hold there. Distribution packages may carry a backported fix under an older version number; confirm against the distribution's own advisory.

Verify against the linked advisories before concluding, and cite the date you read each one:
- https://git.kernel.org/stable/c/9bb37c10bbd57a4a2b7fa61f7c4af479225d0c11
- https://git.kernel.org/stable/c/daee49d7a51f1edb062581d49684c9cbfb3d7dc9
- https://git.kernel.org/stable/c/d6074ea8379b4bee953883f3bfa684cbc284eeeb
- https://git.kernel.org/stable/c/570c783a96f054dd3ac409a92772e9afb705d21c
Do not conclude an asset is unaffected unless you checked it and the evidence covers both its version and the conditions above. If you could not check something, mark it unknown and say what is missing.

Report a table with one row per asset and these columns: Asset | Version or build | Status (affected, fixed, not applicable, unknown) | Compensating controls | Exposure (internet-facing, internal, none) | Evidence | Next action.

Entry: https://cve.now/CVE-2026-99427
For follow-up questions, use the cve.now MCP server at https://mcp.cve.now/mcp (no authentication), for example execute with name cve.get and arguments {"id": "CVE-2026-99427"}.

Affected versions

cve.now Index

20Pof 100 · provisional · methodology v3
  • Exploitation?/40Unknown. No CISA SSVC exploitation rating yet
  • Exposure?/25Unknown. No advisory context yet
  • Reach20/20Affects Linux kernel (software on nearly every server, desktop or phone)
  • Severity?/10Unknown. No CVSS score or vendor rating
  • No patch0/5No signal

What would change the score

  • Would score about 75 if added to CISA KEV
  • Would score about 70 if CISA's SSVC rates exploitation active
  • Would score about 42 if advisories confirm default setups are exposed

Timeline

  1. CVE published
  2. First seen by cve.now

Evidence 6

Questions about CVE-2026-99427

Is CVE-2026-99427 being exploited?

It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.

Source: cve.now feed data

Which versions are affected by CVE-2026-99427?

Linux: from 2.6.25.19 before 2.6.26; from 2.6.26.7 before 2.6.27; from 2.6.27.2 before 2.6.28. Linux: version 2.6.28.

Source: cve.now feed data

How do I fix CVE-2026-99427?

Upgrade to a fixed version: 2.6.26, 2.6.27, 2.6.28.

Source: cve.now feed data

No corrections so far. Something wrong on this page? Report an error.