Skip to contentSkip to conversation

CVE-2026-99387: smb: client: bound POSIX lock data area by response length

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:

smb: client: bound POSIX lock data area by response length

CIFSSMBPosixLock() receives a TRANS2 response whose server-provided DataOffset and DataCount are not required by validate_t2() to describe an interval inside the response. A server can therefore make the client read a cifs_posix_lock beyond the response buffer and return those kernel bytes through F_GETLK.

Use smbCalcSize() to obtain the full response length after any multipart TRANS2 reassembly, then reject data areas that extend past it before dereferencing them.

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

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

	Issue introduced in 2.6.17 with commit fc94cdb94462e71a4a974bc9bc1f483189ae7805 and fixed in 6.12.118 with commit 659148924f05cfc453cca39b885d76b25b84cc29
	Issue introduced in 2.6.17 with commit fc94cdb94462e71a4a974bc9bc1f483189ae7805 and fixed in 6.18.64 with commit 9b75ba374fe03e3650d86fe9cf7fcec117389516
	Issue introduced in 2.6.17 with commit fc94cdb94462e71a4a974bc9bc1f483189ae7805 and fixed in 7.3.2 with commit d5993c6146ad74a3dab2d9cbd09106d644d761cb
	Issue introduced in 2.6.17 with commit fc94cdb94462e71a4a974bc9bc1f483189ae7805 and fixed in 7.4-rc1 with commit 8fc9af68c57156ff64769f30e831553cd03b3000

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-99387

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/client/cifssmb.c
fs/smb/client/trace.h

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/659148924f05cfc453cca39b885d76b25b84cc29
	https://git.kernel.org/stable/c/9b75ba374fe03e3650d86fe9cf7fcec117389516
	https://git.kernel.org/stable/c/d5993c6146ad74a3dab2d9cbd09106d644d761cb
	https://git.kernel.org/stable/c/8fc9af68c57156ff64769f30e831553cd03b3000