We’ve trained people unskilled in IT that’s apps are dangerous and websites are safer. They’ve finally gotten it.
So let’s make websites unsafe, only one click away (which we know users will click)! What a great idea!
Running a downloaded executable is already "one click away", and connecting a website to a Bluetooth device isn't nearly as dangerous as running an executable. The difference in levels of access and size of the exposed attack surface is huge.
WebDRM: subvert control of the machine from the user.
WebUSB: allow browser-based attacks on physically connected hardware.
WebBLE: allow browser-based attacks on wirelessly connected gadgets too!
What’s next? WebDMA? WebFdisk?
The one exception I can think of might be WebAssembly, but to date most native features (like location, filesystem access, even manipulating the DOM) require interop with JS to be used by wasm.
No. But I wouldn't grant a "random" website hardware access either.
A reputable native program with a legitimate reason for requesting hardware access though? Sure. Why shouldn't I be able to do the same for a reputable website?