Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- :::::::::::::::::::::::::::::::::::::::::::::
- ::Made by RU$$ [http://russdev.mooo.com/] ::
- ::BATCH IDLock | Look for keycard text file::
- :::::::::::::::::::::::::::::::::::::::::::::
- @ECHO OFF
- @SETLOCAL
- @TITLE BATCH IDLock ^| Look for keycard text file
- :::::::::::::::::::::::::::::::::::::::::::::
- ::CONFIG | Select a drive to have as IDLock
- ::
- set DRIVE=D:
- set PASSWORD=FallenSpaceHolder
- ::Put this in KeyCode.txt (Make it read only!)
- ::
- ::key=RmFsbGVuU3BhY2VIb2xkZXI
- :::::::::::::::::::::::::::::::::::::::::::::
- Echo Waiting for correct keycode. Insert keycard in drive (%DRIVE%)
- :START
- if exist "%DRIVE%\KeyCode.txt" (goto :EX) else (goto :START)
- :EX
- ::GetKeyFromDRIVE
- for /f "delims== tokens=1,2" %%G in (%DRIVE%\KeyCode.txt) do set %%G=%%H
- <!-- : batch portion
- call :atob b64[0] %key%
- goto :CON
- goto :EOF
- :btoa <var_to_set> <str>
- :atob <var_to_set> <str>
- for /f "delims=" %%I in ('cscript /nologo "%~f0?.wsf" %0 "%~2"') do set "%~1=%%I"
- goto :EOF
- : VBScript -->
- <job>
- <script language="VBScript">
- Set htmlfile = WSH.CreateObject("htmlfile")
- htmlfile.write("<meta http-equiv='x-ua-compatible' content='IE=10' />")
- if WSH.Arguments(0) = ":btoa" then
- WScript.Echo htmlfile.parentWindow.btoa(WSH.Arguments(1))
- else
- WScript.Echo htmlfile.parentWindow.atob(WSH.Arguments(1))
- end if
- </script>
- </job>
- :CON
- cls
- Echo Waiting for correct keycode. Insert keycard in drive (%DRIVE%)
- if exist "%DRIVE%\KeyCode.txt" (Echo [wrong keycode detected])
- if %b64[0]%==%PASSWORD% (goto :VALID) else (goto :START)
- :VALID
- cls
- echo The keycard password is correct!
- echo.
- pause.
- cd C:\Windows\System32
- start calc.exe
- exit.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement