Linux Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsOperating SystemsLinux Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old March 1st, 2013, 04:58 AM
Cyrebo Cyrebo is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2013
Posts: 1 Cyrebo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 m 17 sec
Reputation Power: 0
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.

Reply With Quote
  #2  
Old March 1st, 2013, 06:52 AM
salem's Avatar
salem salem is offline
Contributed User
Click here for more information
 
Join Date: Jun 2005
Posts: 3,840 salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)salem User rank is General 12nd Grade (Above 100000 Reputation Level)  Folding Points: 153 Folding Title: Novice Folder
Time spent in forums: 2 Months 3 Weeks 2 Days 19 h 21 m 53 sec
Reputation Power: 1774
http://linux.die.net/man/8/modprobe

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.
__________________
If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
If at first you don't succeed, try writing your phone number on the exam paper

Reply With Quote
  #3  
Old April 12th, 2013, 03:10 PM
ManuelNewbie ManuelNewbie is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2013
Posts: 23 ManuelNewbie User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 4 h 32 m 7 sec
Reputation Power: 0
Hey

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.

Regards


Quote:
Originally Posted by Cyrebo
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.

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsLinux Help > Optimize Linux Sytem to reject unkown usb devices

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap