CVE-2026-31606·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: f_hid: don't call cdev_init while cdev in use When calling unbind, then bind again, cdev_init reinitialized the cdev, even though there may still be references to it. That's the case when the /dev/hidg* device is still opened. This obviously unsafe behavior like oopes. This fixes this by using cdev_alloc to put the cdev on the heap. That way, we can simply allocate a new one in hidg_bind.
- Severity
- medium
- Software
- Kernel
- Fixed in
- 7.0.1
- Published
How likely is exploitation
FIRST's Exploit Prediction Scoring System puts the probability of this CVE being exploited in the next 30 days at 0.16% — higher than 5% of all published CVEs. EPSS is an independent forecast of exploitation, not a severity rating: it says nothing about how much damage a successful attack does, which is what a CVSS score measures.
Affected versions
From: 7.0
Until: 7.0.1
Fixed in: 7.0.1
How to fix this CVE
Update your Linux kernel to version 7.0.1 or later to resolve a critical USB HID gadget driver issue where repeated bind/unbind cycles can cause kernel oops and memory corruption. The vulnerability stems from unsafe reinitialization of character device structures while they may still be referenced by user-space applications. Apply the kernel update and reboot your system to fully mitigate this flaw.
sudo dnf update kernel && sudo rebootDefensia detects this vulnerability
How to check if you are affected
- Run 'uname -r' to display the currently running kernel version and compare it against version 7.0.1
- Check dmesg output for USB HID gadget warnings: dmesg | grep -i 'hidg\|usb.*gadget' to identify if the vulnerable component is loaded
- Search kernel logs for oops messages tied to character device operations: grep -i 'cdev\|oops' /var/log/kern.log to detect past exploitation attempts
- Verify the fix by confirming the kernel version post-reboot with 'uname -r' and ensure no warnings appear during USB HID gadget initialization
FAQ
What is CVE-2026-31606?
CVE-2026-31606 is a memory safety vulnerability in the Linux kernel's USB HID gadget driver that occurs when the character device is reinitialized while still in use, potentially causing kernel crashes and data corruption for processes holding open file descriptors.
Is CVE-2026-31606 being actively exploited?
No, this vulnerability is not currently listed in the CISA Known Exploited Vulnerabilities (KEV) catalog and no public exploits are available, though it remains a stability risk on affected systems.
What versions of Kernel are affected by CVE-2026-31606?
Linux kernel versions 7.0 through 7.0.1 are affected. The vulnerability is resolved in kernel version 7.0.1 and later.
How do I check if my server is vulnerable to CVE-2026-31606?
Run 'uname -r' to check your kernel version; if it shows 7.0 or 7.0.0, your system is vulnerable. Cross-reference against your distribution's security advisories for exact affected package versions.
Does Defensia detect CVE-2026-31606?
Yes — Defensia's CVE advisory scanner compares installed kernel versions against the NVD database. If Kernel is installed on a monitored server, CVE-2026-31606 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
- https://git.kernel.org/stable/c/3aa77f5da0ecb00895411f4246d8a3e4db0343c2
- https://git.kernel.org/stable/c/5a229016ca3ac551294ec59770be9da94ec4bf63
- https://git.kernel.org/stable/c/75ecc46828ec377dd5692c677168ef6d64fd7123
- https://git.kernel.org/stable/c/81ebd43cc0d6d106ce7b6ccbf7b5e40ca7f5503d
- https://git.kernel.org/stable/c/92f23ab86d9524bc51dae25ed916d0e69dce5992
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2026-31606. Free for 1 server.
Get started free