PT-2025-17665
CVE-2025-40314
·
Published
2025-04-23
·
Updated
2026-10-18
Description by
CVSS 3.1
7.8
HighMetricsAV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Name of the Vulnerable Software and Affected Versions
Linux kernel (affected versions not specified)
Description
A use-after-free issue exists in the Linux kernel’s USB subsystem, specifically within the cdns3 gadget driver. The issue occurs in the
cdnsp gadget init() and cdnsp gadget exit() functions, where the gadget structure is freed before its endpoints, leading to dangling pointers in the endpoint list. Subsequently freeing the endpoints results in a use-after-free condition. The fix involves separating the usb del gadget udc() operation into distinct "del" and "put" steps, ensuring that endpoints are freed before the gadget structure is released.Recommendations
At the moment, there is no information about a newer version that contains a fix for this vulnerability.
Found an issue in the description? Have something to add? Feel free to write us 👾