CVE-2025-40315: Linux kernel · usb: gadget: f_fs: Fix epfile null pointer access after ep enable.
Source GCVE Database
Not known to be exploited.
Data as of 25 Nov 2026, 21:39 UTC
Rated Medium by Threat Radar's AI analysis · No CVSS score from NVD or the CNA
Exploitation evidence
Disclosed: evidence found.
CVE published 8 Dec 2025
Detectable: no evidence on record.
No public nuclei template indexed
Weaponized: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 25 Nov 2026.
What to do
AI-suggested
A fix has been implemented by adding NULL pointer handling in the ffs_func_eps_enable() function. Users should apply the official Linux kernel update that includes this fix. No additional mitigation steps are indicated.
Description
A race condition vulnerability in the Linux kernel's USB gadget function (f_fs) could lead to a NULL pointer dereference due to concurrent access to the epfiles pointer. This issue is fixed by adding NULL pointer handling in the affected function.
References
- nvd.nist.gov/vuln/detail/CVE-2025-40315 (opens in a new tab)
- git.kernel.org/stable/c/1c0dbd240be3f87cac321b14e17979b7e9cb6a8f (opens in a new tab)
- git.kernel.org/stable/c/30880e9df27332403dd638a82c27921134b3630b (opens in a new tab)
- git.kernel.org/stable/c/9ec40fba7357df2d36f4c2e2f3b9b1a4fba0a272 (opens in a new tab)
- git.kernel.org/stable/c/b00d2572c16e8e59e979960d3383c2ae9cebd195 (opens in a new tab)
- git.kernel.org/stable/c/c53e90563bc148e4e0ad09fe130ba2246d426ea6 (opens in a new tab)
- git.kernel.org/stable/c/cfd6f1a7b42f62523c96d9703ef32b0dbc495ba4 (opens in a new tab)
- git.kernel.org/stable/c/d62b808d5c68a931ad0849a00a5e3be3dd7e0019 (opens in a new tab)
- git.kernel.org/stable/c/fc1141a530dfc91f0ee19b7f422a2d24829584bc (opens in a new tab)