mcb: fix error handling in mcb_alloc_bus()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 18d28819809909c3f24bb72183a901c5e332a63d · < 9fc198f415dee070a1de957bb5bf5921d8df3499| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
mcb: fix error handling in mcb_alloc_bus()
There are two bugs: 1) If ida_simple_get() fails then this code calls put_device(carrier) but we haven't yet called get_device(carrier) and probably that leads to a use after free. 2) After device_initialize() then we need to use put_device() to release the bus. This will free the internal resources tied to the device and call mcb_free_bus() which will free the rest.
From the CVE record · Linux
The Linux kernel's mcb_alloc_bus() has error-handling bugs that can lead to a use-after-free if ida_simple_get() fails. The input does not specify how an attacker could trigger the failure or whether access, authentication, or user interaction is required.
Engineers running Linux kernels with the affected mcb_alloc_bus() code should check their kernel versions; no affected versions are listed in the input.