linux/sound/usb
Cássio Gabriel 5c09382f1d ALSA: ua101: Reject too-short USB descriptors
commit b59d5c51bb upstream.

find_format_descriptor() walks the class-specific interface extras by
advancing with bLength. It rejects descriptors that extend past the
remaining buffer, but it does not reject descriptor lengths smaller than
a USB descriptor header.

Reject too-short descriptors before using bLength to advance the local
scan. This keeps the UA-101 parser robust against malformed descriptor
data and matches the usual USB descriptor walking rules.

Fixes: 63978ab3e3 ("sound: add Edirol UA-101 support")
Cc: stable@vger.kernel.org
Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com>
Link: https://patch.msgid.link/20260519-alsa-ua101-desc-len-v1-1-4307d1a5e054@gmail.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2026-06-01 17:35:46 +02:00
..
6fire ALSA: 6fire: Fix input volume change detection 2026-06-01 17:35:15 +02:00
bcd2000 ALSA: bcd2000: Fix a UAF bug on the error path of probing 2022-08-17 14:22:46 +02:00
caiaq ALSA: caiaq: fix usb_dev refcount leak on probe failure 2026-06-01 17:35:18 +02:00
hiface module: remove never implemented MODULE_SUPPORTED_DEVICE 2021-03-17 13:16:18 -07:00
line6 ALSA: line6: add hw monitor volume control to POD HD500X 2024-10-17 15:11:36 +02:00
misc ALSA: ua101: Reject too-short USB descriptors 2026-06-01 17:35:46 +02:00
usx2y ALSA: usx2y: validate nrpacks module parameter on probe 2025-03-13 12:51:05 +01:00
card.c ALSA: usb-audio: Fix NULL pointer deference in try_to_register_card 2025-10-29 14:03:09 +01:00
card.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2024-03-15 10:48:19 -04:00
clock.c ALSA: usb-audio: Fix out of bounds reads when finding clock sources 2024-12-14 19:51:11 +01:00
clock.h ALSA: usb-audio: Constify audioformat pointer references 2020-11-23 15:15:36 +01:00
endpoint.c ALSA: usb-audio: Evaluate packsize caps at the right place 2026-06-01 17:35:13 +02:00
endpoint.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2024-03-15 10:48:19 -04:00
format.c ALSA: usb-audio: stop parsing UAC2 rates at MAX_NR_RATES 2026-06-01 17:35:13 +02:00
format.h ALSA: usb: initial USB Audio Device Class 3.0 support 2018-03-21 11:46:33 +01:00
helper.c ALSA: usb-audio: Add snd_usb_get_host_interface() helper 2020-11-23 15:13:47 +01:00
helper.h ALSA: usb-audio: Add snd_usb_get_host_interface() helper 2020-11-23 15:13:47 +01:00
implicit.c ALSA: usb-audio: Add implicit feedback quirk for RODE AI-1 2025-06-27 11:05:21 +01:00
implicit.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2024-03-15 10:48:19 -04:00
Kconfig sound: Fix Kconfig indentation 2019-10-07 03:53:03 +02:00
Makefile ALSA: usb-audio: Factor out the implicit feedback quirk code 2020-11-23 15:17:00 +01:00
media.c ALSA: usb-audio: fix spelling mistakes 2021-07-05 19:33:54 +02:00
media.h media: sound/usb: Use Media Controller API to share media resources 2019-04-22 11:21:06 -04:00
midi.c ALSA: usb-audio: Bound MIDI endpoint descriptor scans 2026-06-01 17:35:44 +02:00
midi.h ALSA: usb-audio: generate midi streaming substream names from jack names 2021-03-01 09:21:54 +01:00
mixer.c Revert "ALSA: usb: Increase volume range that triggers a warning" 2026-06-01 17:35:14 +02:00
mixer.h ALSA: usb-audio: Add input value sanity checks for standard types 2024-10-17 15:11:27 +02:00
mixer_maps.c ALSA: usb-audio: Rename ALSA kcontrol PCM and PCM1 for the KTMicro sound card 2025-06-27 11:05:34 +01:00
mixer_quirks.c ALSA: usb-audio: Fix Audio Advantage Micro II SPDIF switch 2026-06-01 17:35:13 +02:00
mixer_quirks.h ALSA: usb-audio: Initialize Dell Dock playback volumes 2018-05-02 16:02:32 +02:00
mixer_s1810c.c ALSA: usb-audio: add mono main switch to Presonus S1824c 2025-12-07 06:09:24 +09:00
mixer_s1810c.h ALSA: usb-audio: Add support for Presonus Studio 1810c 2020-02-15 09:46:16 +01:00
mixer_scarlett.c ALSA: usb-audio: fix spelling mistakes 2021-07-05 19:33:54 +02:00
mixer_scarlett.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mixer_scarlett_gen2.c ALSA: scarlett2: Fix buffer overflow in config retrieval 2026-02-06 16:42:03 +01:00
mixer_scarlett_gen2.h ALSA: usb-audio: scarlett2: Improve driver startup messages 2021-05-21 16:22:52 +02:00
mixer_us16x08.c ALSA: usb-mixer: us16x08: validate meter packet indices 2026-01-19 13:09:46 +01:00
mixer_us16x08.h ALSA: usb: Constify snd_kcontrol_new items 2020-01-03 09:24:34 +01:00
pcm.c ALSA: usb-audio: Fix possible NULL pointer dereference in snd_usb_pcm_has_fixed_rate() 2024-10-17 15:11:48 +02:00
pcm.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2024-03-15 10:48:19 -04:00
power.c ALSA: usb-audio: More validations of descriptor units 2019-08-22 10:35:59 +02:00
power.h ALSA: usb-audio: Initial Power Domain support 2018-07-31 15:01:22 +02:00
proc.c ALSA: usb-audio: Show sync endpoint information in proc outputs 2020-11-23 15:16:45 +01:00
proc.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
quirks-table.h ALSA: usb-audio: Fix Yamaha P-125 Quirk Entry 2024-12-14 19:50:41 +01:00
quirks.c ALSA: usb-audio: Update for native DSD support quirks 2026-06-01 17:35:04 +02:00
quirks.h ALSA: usb-audio: Register card at the last interface 2022-10-26 12:35:39 +02:00
stream.c ALSA: usb-audio: Fix UAC3 cluster descriptor size check 2026-06-01 17:35:20 +02:00
stream.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
usbaudio.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2024-03-15 10:48:19 -04:00
validate.c ALSA: usb-audio: Use correct version for UAC3 header validation 2026-04-18 10:33:09 +02:00