media: pvrusb2: fix use after free on context disconnection
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ e5be15c63804e05b5a94197524023702a259e308 · < 2cf0005d315549b8d2b940ff96a66c2a889aa795| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
media: pvrusb2: fix use after free on context disconnection
Upon module load, a kthread is created targeting the pvr2_context_thread_func function, which may call pvr2_context_destroy and thus call kfree() on the context object. However, that might happen before the usb hub_event handler is able to notify the driver. This patch adds a sanity check before the invalid read reported by syzbot, within the context disconnection call stack.
From the CVE record · Linux
The Linux kernel pvrusb2 driver has a use-after-free during context disconnection. A thread created at module load may free the context before the USB hub event handler notifies the driver, leading to an invalid read. The input does not specify attacker access requirements or user interaction.
Engineers running Linux kernels with the pvrusb2 driver should check their installations; affected versions are not specified.