Wednesday, April 23, 2008

Protecting flash drive from virus.

When we have to use public computer sometimes we often sulky because when we finish using it, our flash drive is full with virus, worm or other malware. There is an easy way to overcome this matter.

Yesterday when I surfing at a site, I see an article concerning to this problem. The article advise that is a function in registry to protect flash disk. The principle same as protect our hard drive. Actually if our flash drive own a knob for locking flash drive to become write protect, this thing is not a problem. But how with flash drive which don't have the knob? Of course this will become a problem .

For protecting flash drive, we open a value in registry at the following address :

"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies"

With dword value" WriteProtect". We remain to change value found on dword value" WriteProtect" to become 1 .

If the registry editor is protected, we can make a program functioning to alter value registry with Batch Programming.

All we need is a text editor like notepad. Then typed the code below :

+++++++++++++++++++++++++Cut Here++++++++++++++++++++++++++++
@echo off
echo Visit my blog for more news and tutorial
echo www.bugtrax.blogspot.com

reg add "hklm\system\CurrentControlSet\Control\StorageDevicePolicies" /v WriteProtect /t REG_DWORD /d 1 /f
echo Your registry has been change!!
+++++++++++++++++++++++++Cut Here++++++++++++++++++++++++++++

Then Save As Type : All Files with any name you like.You can upload this program, then when you will using your flash drive in public computer, you can download this program and use it before you use the flash drive.

No comments: