C Board  

Go Back   C Board > Community Boards > Tech Board

Reply
 
LinkBack Thread Tools Display Modes
Old 01-15-2009, 09:15 AM   #1
and the hat of copycat
 
stevesmithx's Avatar
 
Join Date: Sep 2007
Posts: 417
Write protecting USB drive

Recently when I used my usb drive on another computer the files on my usb drive got infected by worms.
Is there any way to make an usb drive inherently write-protected like floppy disks with any software so that worms won't be able to infect it.
I searched for this but all solutions depend on tinkering with target computer(infected PC) registry. Utilities like thumbscrew also seem to give a similar solution.
Is there some kind of utility which would make the usb drive write-protected at my PC and does not involve tinkering with target computer's registry.
Does anyone know of any such utility or is it even possible to do this?
I heard some usb drives have write-protection toggle like those in floppy disks but mine doesn't have this.
__________________
Not everything that can be counted counts, and not everything that counts can be counted
- Albert Einstein.


No programming language is perfect. There is not even a single best language; there are only languages well suited or perhaps poorly suited for particular purposes.
- Herbert Mayer

Last edited by stevesmithx; 01-15-2009 at 09:19 AM.
stevesmithx is offline   Reply With Quote
Old 01-15-2009, 01:30 PM   #2
CSharpener
 
vart's Avatar
 
Join Date: Oct 2006
Posts: 5,328
probably easier will be to find a USB-drive with lock-slider preventing write access on the hardware level
__________________
If I have eight hours for cutting wood, I spend six sharpening my axe.
vart is offline   Reply With Quote
Old 01-16-2009, 01:46 AM   #3
and the hat of copycat
 
stevesmithx's Avatar
 
Join Date: Sep 2007
Posts: 417
Yeah but as i said earlier mine doen't have lock-slider to toggle write-protection.
__________________
Not everything that can be counted counts, and not everything that counts can be counted
- Albert Einstein.


No programming language is perfect. There is not even a single best language; there are only languages well suited or perhaps poorly suited for particular purposes.
- Herbert Mayer
stevesmithx is offline   Reply With Quote
Old 01-16-2009, 02:28 AM   #4
Malum in se
 
abachler's Avatar
 
Join Date: Apr 2007
Posts: 3,188
Without a switchm, any solution will be software based, which means tinkering with every computer that uses it, and of course the worms are free to ignore the software protection.

So the answer is NO, buy one with a switch.
__________________
Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.
abachler is offline   Reply With Quote
Old 01-16-2009, 07:43 AM   #5
and the hat of copycat
 
stevesmithx's Avatar
 
Join Date: Sep 2007
Posts: 417
Quote:
Without a switchm, any solution will be software based, which means tinkering with every computer that uses it, and of course the worms are free to ignore the software protection.

So the answer is NO, buy one with a switch.
Actually I searched and found certain unfamiliar for-a-fee software which claimed to do this perfectly. But I didn't want to end up buying some crap which is either fake or a virus itself!
Anyway as you say the better solution would be to use a hardware lock,i guess.
__________________
Not everything that can be counted counts, and not everything that counts can be counted
- Albert Einstein.


No programming language is perfect. There is not even a single best language; there are only languages well suited or perhaps poorly suited for particular purposes.
- Herbert Mayer
stevesmithx is offline   Reply With Quote
Old 01-16-2009, 08:41 AM   #6
Kernel hacker
 
Join Date: Jul 2007
Location: Farncombe, Surrey, England
Posts: 15,686
The only way you can actually achieve this without hardware support would be to use a (filter-)driver that declines writes to that particular device. It can certainly be done, but it's not entirely trivial.

--
Mats
__________________
Compilers can produce warnings - make the compiler programmers happy: Use them!
Please don't PM me for help - and no, I don't do help over instant messengers.
matsp is offline   Reply With Quote
Old 01-17-2009, 10:28 AM   #7
and the hat of copycat
 
stevesmithx's Avatar
 
Join Date: Sep 2007
Posts: 417
Thanks Mats.
__________________
Not everything that can be counted counts, and not everything that counts can be counted
- Albert Einstein.


No programming language is perfect. There is not even a single best language; there are only languages well suited or perhaps poorly suited for particular purposes.
- Herbert Mayer
stevesmithx is offline   Reply With Quote
Old 01-17-2009, 03:54 PM   #8
Senior software engineer
 
brewbuck's Avatar
 
Join Date: Mar 2007
Location: Portland, OR
Posts: 5,768
Damn USB thumb drives are like heroin needles. People pass them around like crazy. And because most people's systems are configured for autorun when a thumb drive is plugged in, viruses and other things can spread too easily.

EVERY thumb drive should have a hardware write protect switch. I can't believe some don't.
__________________
"Congratulations on your purchase. To begin using your quantum computer, set the power switch to both off and on simultaneously." -- raftpeople@slashdot
brewbuck is offline   Reply With Quote
Old 01-17-2009, 04:37 PM   #9
Registered User
 
Join Date: Dec 2006
Location: Canada
Posts: 2,009
IMHO autorun is inherently wrong. At least pop up a menu like Vista does (IIRC?). Plugging in a thumb drive = giving consent to executing arbitrary code is just wrong.
cyberfish is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[Hardware + Software][C++ or C#] USB Fan Mywk C++ Programming 16 07-04-2009 03:12 PM
Extracting data from a laptop hard drive DavidP Tech Board 6 06-13-2009 07:02 AM
Usb 2.0 ober Tech Board 6 09-06-2003 10:14 AM
Printers On USB (TNT) A Brief History of Cprogramming.com 1 03-10-2002 11:48 AM
This should be the Cprogramming.com anthem! Brian A Brief History of Cprogramming.com 6 01-21-2002 12:01 AM


All times are GMT -6. The time now is 04:06 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22