Skip to contentSkip to conversation

CVE-2026-99565: ksmbd: wait for negotiation before receiving another PDU

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Nov 19

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

Description
===========

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

ksmbd: wait for negotiation before receiving another PDU

The receive thread queues a request and can read the next PDU before the negotiation worker finishes. While need_neg is set, the next PDU can cause ksmbd_init_smb_server() to replace conn->ops. A pipelined SMB2 request can therefore make the worker handle an earlier, shorter SMB1 request with SMB2 operations and read beyond its buffer.

An SMB1 multi-protocol negotiate may be followed by an SMB2 NEGOTIATE that changes conn->ops again. Wait for work queued while the connection is new or needs negotiation to complete before reading another PDU. This keeps the operations stable for both stages of negotiation without changing when need_neg is cleared.

The Linux kernel CVE team has assigned CVE-2026-99565 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 6.3 with commit dc8289f912387c3bcfbc5d2db29c8947fa207c11 and fixed in 6.12.117 with commit a9039d6c9de5dfd91f360b085da75899055b15a5
	Issue introduced in 6.3 with commit dc8289f912387c3bcfbc5d2db29c8947fa207c11 and fixed in 6.18.61 with commit 49675f7bc0e1ae12a60f6af5cb2b800eb39fe055
	Issue introduced in 6.3 with commit dc8289f912387c3bcfbc5d2db29c8947fa207c11 and fixed in 7.2.15 with commit aaf8a64a3fbf745eddea729fe27c6e22f4a009e2
	Issue introduced in 6.3 with commit dc8289f912387c3bcfbc5d2db29c8947fa207c11 and fixed in 7.3.2 with commit d4a52e78378a501ae38f676e85a60a2a6c21af35
	Issue introduced in 6.3 with commit dc8289f912387c3bcfbc5d2db29c8947fa207c11 and fixed in 7.4-rc1 with commit 68f410faedaf6ee74d81e574733c50ebcc1bd8ed
	Issue introduced in 5.15.145 with commit 921536046bd165efeb07beef5630aff35cd6a489
	Issue introduced in 6.1.24 with commit a8334a0c535d0f0b4d64926c8fe0922ed98f7d43
	Issue introduced in 6.2.11 with commit 99a51c673b1d2d0b5a972353401b77612d9cc713

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2026-99565

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
fs/smb/server/server.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/a9039d6c9de5dfd91f360b085da75899055b15a5
	https://git.kernel.org/stable/c/49675f7bc0e1ae12a60f6af5cb2b800eb39fe055
	https://git.kernel.org/stable/c/aaf8a64a3fbf745eddea729fe27c6e22f4a009e2
	https://git.kernel.org/stable/c/d4a52e78378a501ae38f676e85a60a2a6c21af35
	https://git.kernel.org/stable/c/68f410faedaf6ee74d81e574733c50ebcc1bd8ed