Connecting to uncommon HID devices
web.dev
web.dev
Why not a whitelist? And, while I'm definitely not one to side with the Google/Chrome crowd on allowing sites more access to anything, one could argue that allowing an authentication device to communicate with a webapp is useful...
Of course, the biggest concern is not the mere existing of this feature, but how much users will be able to control it --- which, given the seemingly authoritarian stance that companies like Google have ("we know what's best for everyone"), I'm not too hopeful for.
Sadly every runtime (including native executables) that isn't the web browser is treated as a security risk, while web "pages" running arbitrary code with any level of local hardware access are seen as safe, so I think we're stuck with the web stack for the long haul.
I can see at least three collision sources: 1. A lot of hobbyist HID projects exist, which invites use of the firmware default IDs, even if the devices differ quite a bit from the original model. 2. Bargain-basement manufacturers probably don't register for unique IDs for every single product. 3. The legitimate case of multiple equivalent devices on a single machine. I could see using, say, multiple programmable keyboards but wanting to address each one individually.
WebHID seems like a bad idea.