drm/amdgpu/vce: fix integer overflow in image size
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ f1689ec1b0b1256d0e69653cd4aaeee44aafdf5c · < 186bfdc4e26d019b2e7570cb121964a1d89b2e5b| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
drm/amdgpu/vce: fix integer overflow in image size
Fix a security vulnerability where malicious VCE command streams with oversized dimensions (e.g. 65536×65536) cause 32-bit integer overflow, wrapping the calculated buffer size to 0. This bypasses validation and allows GPU firmware to perform out-of-bound memory access.
The fix uses 64-bit arithmetic to detect overflow and rejects invalid dimensions before they reach the hardware.
V2: remove redundant check V3: modify max height value V4: remove size64
(cherry picked from commit cbe408dba581755ad1279a487ec786d8927d778d)
From the CVE record · Linux
The Linux kernel’s amdgpu VCE code can overflow a 32-bit buffer-size calculation for command streams with oversized image dimensions. An attacker who can submit a malicious VCE command stream could bypass validation and cause GPU firmware to access memory out of bounds. The input does not specify whether this requires local access, authentication, or user interaction.
Engineers running the Linux kernel with amdgpu VCE should check their installations; affected versions are not specified.