Subject: CVE-2024-35999: smb3: missing lock when picking channel

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

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

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

smb3: missing lock when picking channel

Coverity spotted a place where we should have been holding the
channel lock when accessing the ses channel index.

Addresses-Coverity: 1582039 ("Data race condition (MISSING_LOCK)")

The Linux kernel CVE team has assigned CVE-2024-35999 to this issue.

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

	Fixed in 6.1.91 with commit 98c7ed29cd75
	Fixed in 6.6.30 with commit 0fcf7e219448
	Fixed in 6.8.9 with commit 60ab24529228
	Fixed in 6.9 with commit 8094a600245e

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-2024-35999
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/transport.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/98c7ed29cd754ae7475dc7cb3f33399fda902729
	https://git.kernel.org/stable/c/0fcf7e219448e937681216353c9a58abae6d3c2e
	https://git.kernel.org/stable/c/60ab245292280905603bc0d3654f4cf8fceccb00
	https://git.kernel.org/stable/c/8094a600245e9b28eb36a13036f202ad67c1f887