What’s Vulnerable › Vulnerabilities
CVE-2025-40117: misc: pci_endpoint_test: Fix array underflow in pci_endpoint_test_ioctl()
- Severity: high (CVSS 7.8 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.2% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2025-11-12 · updated 2026-10-19
Description
In the Linux kernel, the following vulnerability has been resolved: misc: pci_endpoint_test: Fix array underflow in pci_endpoint_test_ioctl() Commit eefb83790a0d ("misc: pci_endpoint_test: Add doorbell test case") added NO_BAR (-1) to the pci_barno enum which, in practical terms, changes the enum from an unsigned int to a signed int. If the user passes a negative number in pci_endpoint_test_ioctl() then it results in an array underflow in pci_endpoint_test_bar().
Affected products
- Linux kernel: 6.17 — fixed in 6.18
How to fix
Upgrade to a fixed version: Linux kernel 6.18. Check the vendor advisory for mitigations.
References
- https://git.kernel.org/stable/c/1ad82f9db13d85667366044acdfb02009d576c5a
- https://git.kernel.org/stable/c/6df3687922570f753574c40b35e83b26b32292d0
Get alerted when CVE-2025-40117 or the next vulnerability affects your stack