Date: Fri, 18 Mar 2016 20:48:07 -0400 From: "Gary Duzan" <g...@duzan.org> Message-ID: <20160319004807.2b63d115...@xen1.duzan.org>
| In Message <rmih9g3tkij....@fnord.ir.bbn.com>, | Greg Troxel <g...@ir.bbn.com>wrote: | =>Perhaps if we had something called uscanner that would match scanners | =>and that libusb would fine, we could have the permissions management of | =>direct matching but the cope-with-the-rest-of-the-world benefit of | =>libusb. I was going to suggest something similar, a driver that connects to ugen internally, so it has the same interface as ugen does for applications (or libusb) to use, but which only works with (only allows access to) usb devices with particular characteristics (such as scanners, or printers, or modems, or UPSs) which could be controlled by matching manufacturer, class, or whatever works... Something like this should be not very hard to do, as it doesn't have to deal with anything complex (and leaves all the real work to the ugen driver underneath, combined with application code above). It would allow permissions to be set on the /dev/xxx entry that are appropriate for the device, without knowing which USB port the device would happen to get plugged into, and without accidentally allowing access to a umass or similar device. | Can we not build some sort of bus-like device to which both the | specialized and generic devices can attach which prevents opening | both at the same time? That I suspect would be quite a bit more work, though it might be useful to allow access to one scanner (or printer, or whatever) via the specialised driver for user code that works that way, or via ugen (and libusb presumably) for user code written that way - whichever one the user wants to use that day. What isn't so clear is just how many people would actually need, and use, that if it was developed, rather than just settling for one application (and hence one access method) for each of scanners, printers, etc. That is, would it really be worth the effort needed to make it work? kre