Junglewise Threat Intelligence

CVE-2025-40354: Linux Kernel AMD display driver NULL pointer dereference and buffer overflow

CVE-2025-40354 · Severity: high · CVSS 7.8 · Published 2025-12-16

Technologies: Linux Kernel. Vendors: Linux.

Executive brief

A vulnerability exists in the Linux kernel's AMD display driver, which manages how the computer communicates with monitors and graphics hardware. An attacker with local access to the system could exploit this flaw to cause a system crash or potentially gain unauthorized access to sensitive information. This issue affects systems using AMD graphics hardware and could impact overall system stability and data security.

Technical details

This vulnerability in the Linux kernel's AMD display driver (drm/amd/display) stems from two primary issues: an undersized array for 'dc->links' and a NULL pointer dereference in 'hw_init()'. The 'MAX_LINKS' constant was incorrectly defined as 12, while the actual requirement for connectors, DPIA, and virtual links is 14, leading to potential out-of-bounds access. Additionally, 'hw_init()' failed to validate the 'link_enc' pointer for non-physical display endpoints, resulting in a NULL pointer dereference. A local attacker can exploit these flaws to cause a denial-of-service (kernel panic) or achieve arbitrary code execution with kernel privileges. Patches have been released in various stable kernel branches to increase the array size and add necessary pointer checks.

Affected products

  • Linux Linux Kernel 4.15 to 6.12.55, 6.17.5

Timeline

  • 2025-12-16: advisory: NVD published the CVE record.
  • 2025-10-29: patched: Fixes committed to stable kernel branches.

References

Related threats