CVE-2023-52921: drm/amdgpu: fix possible UAF in amdgpu_cs_pass1()

Description

In the Linux kernel, the following vulnerability has been resolved:

drm/amdgpu: fix possible UAF in amdgpu_cs_pass1()

Since the gang_size check is outside of chunk parsing
loop, we need to reset i before we free the chunk data.

Suggested by Ye Zhang (@VAR10CK) of Baidu Security.

Classification

CVE ID: CVE-2023-52921

Affected Products

Vendor: Linux

Product: Linux

Exploit Prediction Scoring System (EPSS)

EPSS Score: 0.04% (probability of being exploited)

EPSS Percentile: 5.06% (scored less or equal to compared to others)

EPSS Date: 2025-02-03 (when was this score calculated)

References

https://git.kernel.org/stable/c/9a2393af1f35d1975204fc00035c64a1c792b278
https://git.kernel.org/stable/c/e08e9dd09809b16f8f8cee8c466841b33d24ed96
https://git.kernel.org/stable/c/90e065677e0362a777b9db97ea21d43a39211399

Timeline