ALSA: usb-audio: Fix potential memory leaks
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 8fdff6a319e7dac757c558bd283dc4577e68cde7 · < 0672215994e2347a9b4f145e2bc1709b1e01cee3| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
ALSA: usb-audio: Fix potential memory leaks
When the driver hits -ENOMEM at allocating a URB or a buffer, it aborts and goes to the error path that releases the all previously allocated resources. However, when -ENOMEM hits at the middle of the sync EP URB allocation loop, the partially allocated URBs might be left without released, because ep->nurbs is still zero at that point.
Fix it by setting ep->nurbs at first, so that the error handler loops over the full URB list.
From the CVE record · Linux
The Linux kernel's ALSA USB audio driver can leave partially allocated URBs unreleased if memory allocation fails during the sync endpoint URB allocation loop. This can cause a memory leak; the input does not establish how an attacker could trigger it or whether access, authentication, or user interaction is required.
Engineers running Linux kernels with the ALSA USB audio driver should check their versions; affected versions are not specified.