So, I asked a bit ago on how to make a udev rule to block certain USB devices. However, I need to achieve something like this with wireless USB adapters.
I have a wireless USB adapter from EDIMAX that's a Realtek chipset. I have it in my system for a Kali VM running inside of VMware Workstation, but I want to make it available only to the VM. Having said that, it is on my computer all the time, and I want Ubuntu to not be able to 'use' it as a network card, and only want it used by the VM.
The tricky part: I need to isolate this wifi adapter specifically from being used, while all others are fair game to the system / Network Manager. This one is dedicated for use in a VM, NOT by the host OS, Ubuntu 14.04.
I'm thinking a udev rule to prevent it from being used as a network adapter by Ubuntu is the way to go, but I am not sure how to do this or if this is the method to go. Thoughts on how I can achieve this?
The system I am trying to achieve this on is Ubuntu 14.04.
Requested Information
Relevant lsusb
line:
Bus 001 Device 003: ID 7392:7811 Edimax Technology Co., Ltd EW-7811Un 802.11n Wireless Adapter [Realtek RTL8188CUS]
lsusb
? I too think udev is the way to go. In the meantime a quick and dirty hack could be blacklisting the driver in the host, so that the device is not claimed and it's free to be used from the VM. But it disables all the devices using that driver (if others) and, regardless, it's ugly, I know. Just as temporary solution. – kos Dec 03 '15 at 15:01SUBSYSTEM=="usb", ATTRS{idVendor}=="0a5c", ATTRS{idProduct}=="217f", ATTR{authorized}="0"
, obviously replacing0a5c
and217f
with the values from the relevantlsusb
entry. – kos Dec 03 '15 at 15:27