espressif/usb_host_hid Double-Free Race Condition in USB Host HID Device Close Path
espressif esp-usb
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| espressif esp-usb |
| No fix yet |
Original description
Espressif ESP-IDF USB Host HID (Human Interface Device) Driver allows access to HID devices. Prior to 1.1.0, calls to hid_host_device_close() can free the same usb_transfer_t twice. The USB event callback and user code share the hid_iface_t state without locking, so both can tear down a READY interface simultaneously, corrupting heap metadata inside the ESP USB host stack. This vulnerability is fixed in 1.1.0.
From the CVE record · GitHub_M
References
- github.com/espressif/esp-usb/security/advisories/GHSA-gp8r-qjfr-gqfvVendor advisory
- github.com/espressif/esp-usb/commit/cd28106e9f72ac2719682c06f94601f9f034390bPatch
- components.espressif.com/components/espressif/usb_host_hid/versions/1.1.0/changelogRelease notes
- github.com/CVEProject/cvelistV5/tree/main/cves/2025/68xxx/CVE-2025-68657.json
- nvd.nist.gov/vuln/detail/CVE-2025-68657