Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
sys/linux: extract USB HID ids #1294
As it turns out the HID kernel subsystem registers only one USB driver that
This patch updates the syz-usbgen tool to also extract USB HID vendor/device
This patch also contains some minor improvements to USB descriptions
LGTM but something of CI has failed
Wonder what should we do with vusb_responses long-term... if I understand what happens correctly, soon we may have hundreds of entries there and fuzzer will need to generate all of them for every call and mutations will almost always mutate something unused...
As it turns out the HID kernel subsystem registers only one USB driver that checks that the interface of the connected device has HID class and then looks up its own list of vendor/device ids to find a matching driver. This means that we currently don't generate proper vendor/device ids for USB HID devices. This patch updates the syz-usbgen tool to also extract USB HID vendor/device ids from a running kernel and makes the generated descriptions for HID devices to be patched using the extracted ids. This patch also contains some minor improvements to USB descriptions (better HID descriptions and more replies for some USB classes/drivers).
@@ Coverage Diff @@ ## master #1294 +/- ## ========================================== + Coverage 57.74% 57.76% +0.02% ========================================== Files 131 131 Lines 24611 24631 +20 ========================================== + Hits 14211 14229 +18 - Misses 9724 9727 +3 + Partials 676 675 -1