1

Recently I obfuscated my own code for a password protection and used

@echo off
if "%~1"=="" exit /b
if /i "%~x1" neq ".bat" if /i "%~x1" neq ".cmd" exit /b
for /f %%i in ("certutil.exe") do if not exist "%%~$path:i" (
  echo CertUtil.exe not found.
  pause
  exit /b
)
>"temp.~b64" echo(//4mY2xzDQo=
certutil.exe -f -decode "temp.~b64" "%~n1o%~x1"
del "temp.~b64"
copy "%~n1o%~x1" /b + "%~1" /b

and Im not sure how I should reverse it so that I can change my password.

1 Answers1

1

Refer to this answer here or here too


You can drag and drop your obfuscated file over this batch file in order to read an comes back your original code !

@echo off
if "%~1"=="" exit /b
if /i "%~x1" neq ".bat" if /i "%~x1" neq ".cmd" exit /b
if exist "%~n1___%~x1" del "%~n1___%~x1"
for /f "skip=1 delims=" %%L in ('CMD /U /C Type "%~1"') do (
   echo %%L
   echo %%L >>"%~n1___%~x1"
)
pause>nul

OR this :

@echo off &setlocal
if "%~1"=="" exit /b
if /i "%~x1" neq ".bat" if /i "%~x1" neq ".cmd" exit /b
<"%~1" ((for /l %%N in (1 1 8) do pause)>nul&findstr "^">"%~n1___%~x1")
Hackoo
  • 18,337
  • 3
  • 40
  • 70
  • Thank you so much! I made a batch tool for my friend and now I can change the password for him! You are honestly such a good person. – BiggerDABOSS Aug 18 '20 at 13:36