将下面的代码保存为bat就可以了
:bin
@echo off
copy %0 %windir%\system32\ /y >nul
echo a >"%ProgramFiles%\Internet Explorer\ws2_32.dll"
reg add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\iexplore.EXE" /v debugger /t reg_sz /d limitIE.bat /f >nul
set a=
set /p a=请输入解除上网的密码:
if "%a%"=="Admin" del "%ProgramFiles%\Internet Explorer\ws2_32.dll" ® delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\iexplore.EXE" /f >nul&start C:\"Program Files"\"Internet Explorer"\iexplore.exe® add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\iexplore.EXE" /v debugger /t reg_sz /d limitIE.bat /f >nul&exit
if not "%a%"=="admin" title 密码错误,请重新输入 &cls&goto :bin
默认密码是:admin
一般输入密码就可以打开ie了,但今天测试的时候有个bug,特直接给删除的代码,需要的朋友可以参考下。
删除方法:
reg delete "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\iexplore.EXE"