求一个可以封杀USB接口的批处理
展开全部
@echo off
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\ControlStorageDevicePolicies" /v WriteProtect /t reg_dword /d 1 /f
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR" /v Start /t reg_dword /d 4 /f
copy %windir%\inf\usbstor.inf %windir%\usbstor.inf /y >nul
copy %windir%\inf\usbstor.pnf %windir%\usbstor.pnf /y >nul
del %windir%\inf\usbstor.pnf /q/f >nul
del %windir%\inf\usbstor.inf /q/f >nul
@echo on
新建一个文本文档,把以上复制并保存,然后修改后缀.txt为.bat
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\ControlStorageDevicePolicies" /v WriteProtect /t reg_dword /d 1 /f
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR" /v Start /t reg_dword /d 4 /f
copy %windir%\inf\usbstor.inf %windir%\usbstor.inf /y >nul
copy %windir%\inf\usbstor.pnf %windir%\usbstor.pnf /y >nul
del %windir%\inf\usbstor.pnf /q/f >nul
del %windir%\inf\usbstor.inf /q/f >nul
@echo on
新建一个文本文档,把以上复制并保存,然后修改后缀.txt为.bat
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询