Insufficient validation of untrusted input in USB (CVE-2026-10021)
A logic flaw in WebUSB's permission checks allows a website to bypass the protected class control transfer block by sending a STANDARD type request with an arbitrary bRequest code. This lets an attacker send vendor-specific commands to protected interfaces like HID on devices with non-compliant firmware.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 60 days
Project Fortify, an experimental security project, has identified the following potential security issue.
Overview: A logic flaw in WebUSB's permission checks allows websites to potentially bypass the kWebUsbProtectedClassControlTransferBlock security feature. By sending a STANDARD type request with an arbitrary, non-standard bRequest code, the transfer skips protected interface heuristics and is forwarded to the device. This allows attackers to send vendor-specific commands to protected interfaces (like HID) on devices with non-compliant firmware.
Affected files:
services/device/usb/mojo/device_impl.ccservices/device/usb/device_features.ccservices/device/usb/mojo/device_impl_unittest.ccservices/device/usb/usb_device_handle_usbfs.ccthird_party/blink/renderer/modules/webusb/usb_device.cc
Estimated timestamp from git blame: 2026-03-24
Description
The WebUSB feature kWebUsbProtectedClassControlTransferBlock is designed to prevent websites from communicating with protected interface classes (such as HID, Mass Storage, or Smart Card). Because some device firmware ignores the recipient bits in the bmRequestType byte and routes requests based on wIndex, Chrome blocks VENDOR and CLASS requests to the DEVICE recipient if wIndex matches a protected interface.
However, a logic flaw exists in DeviceImpl::HasControlTransferPermission (services/device/usb/mojo/device_impl.cc). The function contains an early-return optimization that always grants permission if the request type is STANDARD and the recipient is DEVICE or OTHER. This optimization completely skips the wIndex heuristic check against the blocked_interface_classes_ list.
Crucially, the WebUSB implementation does not validate that the bRequest parameter provided by the website is actually a legitimate USB 2.0 standard request (e.g., 0x00-0x0C). A malicious site can specify requestType: 'standard' in JavaScript but provide an arbitrary, vendor-specific request code (e.g., 0x52).
Because the type (bits 5-6) and recipient (bits 0-4) reside in the exact same bmRequestType byte, firmware that is non-compliant with one is highly likely to be non-compliant with the other. The firmware will receive the setup packet, ignore the STANDARD type and DEVICE recipient bits, and execute the arbitrary bRequest on the protected interface specified by wIndex.
Potential Reproduction Steps
Note: These are suggested steps based on code analysis; our tooling agent cannot execute live code.
-
Attach a composite USB device that exposes both an unprotected interface (which can be claimed) and a protected-class interface (e.g., an HID interface at
index: 1). The device firmware must be of the type that ignoresbmRequestTyperouting bits. -
Have a user grant the malicious website WebUSB permission for this device via
navigator.usb.requestDevice(). -
From the website, execute a control transfer targeting the protected interface:
JavaScript device.controlTransferOut({ requestType: 'standard', recipient: 'device', request: 0x52, // Arbitrary vendor-specific request code value: 0, index: 1 // Targets the protected interface }, payload); -
Observe that the browser authorizes the transfer because
requestTypeisstandard. -
The setup packet (
bmRequestType=0x00,bRequest=0x52,wIndex=1) is sent to the device, successfully bypassing the protected class block and compromising the HID interface.
Suggested Fix
To remediate this issue, DeviceImpl::HasControlTransferPermission (or the Blink-side ConvertControlTransferParameters) must strictly validate bRequest when requestType is STANDARD.
The early return in HasControlTransferPermission should only apply if bRequest is a known, safe standard request code (e.g., USB_REQUEST_GET_DESCRIPTOR). Otherwise, the transfer should fall through to the wIndex heuristic checks, or be rejected entirely as an invalid standard request.
Evaluated with Chrome root at commit: a9cbf6e8b275fe4147435aa905f3b7f5a656f5f0
Results from so far have been promising, but there can be wrong deductions. If this proves to be a false positive, please close as WAI; data from false positives will be used to improve accuracy over time. And please feel free to reach out to me directly if you have concerns or feedback on the project.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the permission check returns early for STANDARD requests to the DEVICE recipient without validating that the bRequest code is a real standard request, skipping the protected interface check.
Impact
An attacker could send vendor-specific commands to protected interfaces such as HID on devices with non-compliant firmware, potentially compromising those interfaces.
What the attacker needed
Victim grants WebUSB permission; USB device with non-compliant firmware; device exposes a protected interface
The fix
The permission check should validate that bRequest is a known safe standard request code before granting the early return, otherwise fall through to the wIndex heuristic or reject the transfer.
How it was found
- Attach a composite USB device with an unprotected interface and a protected interface, using firmware that ignores bmRequestType routing bits.
- Have the user grant the malicious website WebUSB permission for the device.
- From the website, send a control transfer with requestType standard, recipient device, an arbitrary request code, and index pointing to the protected interface.
- Observe the browser authorises the transfer because the request type is standard.
- The setup packet reaches the device and bypasses the protected class block.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
WebUSB lets websites talk to USB devices. Chrome tries to stop websites from sending certain commands to sensitive device types like keyboards (HID). This report says a website can pretend its command is a harmless standard request, so Chrome lets it through, and the device may then run a dangerous command.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.