The security of windowns PC is now a big challenge for all the users. The most basic medium through which malwares, viruses and Trojan enter your devices are through pendrives. So, you wish to shield your USB drives from all these unwanted viruses? Then here is the trick that can help you out in this purpose.
This method will help in protecting your pendrives from getting viruses from any computer or device you attach it with.
The steps to prevent pendrives from unwanted viruses are:
First Step:
If your pendrive is having viruses or you thing it can grab some, follow below given steps to prevent it from these unwanted spywares.
- Open Command Prompt (CMD)
- Open Flash drive in cmd (For example: If your drive name is "G" than enter 'G:' after this: c:userG: press enter after this)
- Now enter the following line to cmd:
attrib -s -h /s /d
This step will help to locate all the hidden files in your pen-drive. Now we need to enter some codes that can help in removing and protecting from such files.
Step-2
- Copy following code to notepad:
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlStorageDevicePolicies] WriteProtect=dword:00000001
- Now save the file with extension: ".reg"
- Now your pendrive is save from any kind of unwanted spyware, viruses etc.
How to unshelter your device?
Now to undo this:
- Copy the below code to notepad file:
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlStorageDevicePolicies] WriteProtect=dword:00000000
- Save it with .reg extension.
That's it you are safe now. I hope this tutorial was helpful for you.