It is possible to disable the USB ports on your computer. This will make your computer more secure. It can prevent unnecessary access to your files and protect your computer from the malware that can come from the USB connection. Please note that if you are using a keyboard or mouse that is connected to your computer through USB you should not try this trick because your keyboard or mouse will be disconnected.
open up the Run box by holding the Windows key plus the R key and type Regedit.
Go to USBSTOR by
HKEY_LOCAL_MACHINE / SYSTEM / CurrentControlSet / Services / USBSTOR
look at the right-hand side and double-click Start.
A box will open, in the value data box, replace 3 with 4 and click ok. You will notice that all USB ports on your computer are disabled.
To enable the USB ports back, put 3 in place of 4 in the value data box.