Subject: CVE-2024-27436: ALSA: usb-audio: Stop parsing channels bits when all channels are found.

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

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

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

ALSA: usb-audio: Stop parsing channels bits when all channels are found.

If a usb audio device sets more bits than the amount of channels
it could write outside of the map array.

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

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

	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 4.19.311 with commit 7e2c1b0f6dd9
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 5.4.273 with commit 6d5dc96b154b
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 5.10.214 with commit 5cd466673b34
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 5.15.153 with commit 9af1658ba293
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 6.1.83 with commit 629af0d5fe94
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 6.6.23 with commit 22cad1b841a6
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 6.7.11 with commit c8a24fd281dc
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 6.8.2 with commit 6d88b289fb0a
	Issue introduced in 3.8 with commit 04324ccc75f9 and fixed in 6.9 with commit a39d51ff1f52

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-27436
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:
	sound/usb/stream.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/7e2c1b0f6dd9abde9e60f0f9730026714468770f
	https://git.kernel.org/stable/c/6d5dc96b154be371df0d62ecb07efe400701ed8a
	https://git.kernel.org/stable/c/5cd466673b34bac369334f66cbe14bb77b7d7827
	https://git.kernel.org/stable/c/9af1658ba293458ca6a13f70637b9654fa4be064
	https://git.kernel.org/stable/c/629af0d5fe94a35f498ba2c3f19bd78bfa591be6
	https://git.kernel.org/stable/c/22cad1b841a63635a38273b799b4791f202ade72
	https://git.kernel.org/stable/c/c8a24fd281dcdf3c926413dafbafcf35cde517a9
	https://git.kernel.org/stable/c/6d88b289fb0a8d055cb79d1c46a56aba7809d96d
	https://git.kernel.org/stable/c/a39d51ff1f52cd0b6fe7d379ac93bd8b4237d1b7