In this post, I will show how to create a simple program that disables the USB ports on the computer (PC). As usual, I am using my favorite C programming language to create this program . Anyone with a basic knowledge of C language should be able to understand the working of this program.
Once this program is executed it will immediately disable all the USB ports on the computer. As a result you’ll will not be able to use your pen drive or any other USB peripheral devices on the computer. The source code for this program is available for download. You can test this program on your own computer without any worries since I have also given a program to re-enable all the USB ports.
The download contains the following 2 files:
The idea behind the working of this program is pretty straightforward. It works by gaining access to the Windows registry and modifying its settings to disable the USB device support on the computer.
On the other hand, the other program will re-set the registry settings back to the normal so that the support for USB devices is re-enabled. I hope you like this post. Please pass your comments.