drm: bridge/panel: Cleanup connector on bridge detach
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
drm: bridge/panel: Cleanup connector on bridge detach
If we don't call drm_connector_cleanup() manually in panel_bridge_detach(), the connector will be cleaned up with the other DRM objects in the call to drm_mode_config_cleanup(). However, since our drm_connector is devm-allocated, by the time drm_mode_config_cleanup() will be called, our connector will be long gone. Therefore, the connector must be cleaned up when the bridge is detached to avoid use-after-free conditions.
v2: Cleanup connector only if it was created
v3: Add FIXME
v4: (Use connector->dev) directly in if() block
From the CVE record · Linux
The Linux kernel DRM panel bridge can leave a devm-allocated connector to be cleaned up after it is gone, causing a use-after-free when the bridge is detached. The input does not specify what an attacker could do or whether exploitation requires local access, authentication, or user interaction.
Engineers running Linux kernels with the DRM panel bridge should check their exposure; affected versions are not specified.