Bug 2373460 (CVE-2022-50229) - CVE-2022-50229 kernel: ALSA: bcd2000: Fix a UAF bug on the error path of probing
Summary: CVE-2022-50229 kernel: ALSA: bcd2000: Fix a UAF bug on the error path of probing
Keywords:
Status: NEW
Alias: CVE-2022-50229
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-06-18 12:03 UTC by OSIDB Bzimport
Modified: 2025-06-20 04:01 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2025-06-18 12:03:59 UTC
In the Linux kernel, the following vulnerability has been resolved:

ALSA: bcd2000: Fix a UAF bug on the error path of probing

When the driver fails in snd_card_register() at probe time, it will free
the 'bcd2k->midi_out_urb' before killing it, which may cause a UAF bug.

The following log can reveal it:

[   50.727020] BUG: KASAN: use-after-free in bcd2000_input_complete+0x1f1/0x2e0 [snd_bcd2000]
[   50.727623] Read of size 8 at addr ffff88810fab0e88 by task swapper/4/0
[   50.729530] Call Trace:
[   50.732899]  bcd2000_input_complete+0x1f1/0x2e0 [snd_bcd2000]

Fix this by adding usb_kill_urb() before usb_free_urb().

Comment 1 Avinash Hanwate 2025-06-20 03:50:28 UTC
Upstream advisory:
https://lore.kernel.org/linux-cve-announce/2025061850-CVE-2022-50229-702e@gregkh/T


Note You need to log in before you can comment on or make changes to this bug.