March 1st, 2013, 05:58 AM
Optimize Linux Sytem to reject unkown usb devices
Hi, I'm trying to make my Linux system (Kubuntu 12.10) reject/block all other usb devices except from my own from connecting to the computer. In practice all i want is an error message to come up saying "Unknown Device not permitted on this computer" or something when another usb device is connected.
I don't want the implementation to however disable usb devices connected physically as I do have a Windows 7 installation on the same PC.
Thanks in advance for any advice/ideas on this.
March 1st, 2013, 07:52 AM
You can see what handles USB by typing in say
modprobe -l | grep usb
You can use the modprobe blacklists to prevent whatever module(s) you like from loading.
April 12th, 2013, 04:10 PM
You should have a look into the udev rules. With the udev rules you can specify that only certain usb or any other devices with an UUID are recognised by the machine. This way only your usbs will work. You can also secify in the udev rules to create a file in a certain place if someone puts in a non wanted usb.
You would have to write a bash script to look for that file and if it is created you can display a message with xmessage.
Originally Posted by Cyrebo