Windows Command Line – Password function

Here is a little password function if you need it. Be aware that it is very slow, don’t type too fast. 😉 It’s more a concept than a tool you can work with.

Just Enter your password and hit ALT+222 (on your numblock) to terminate.

@echo off
setLocal EnableDelayedExpansion

set allchar=Þ1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
set pw=

echo Please enter password SLOWLY and terminate with ALT+222
choice /C %allchar% /CS >nul
set cint=%errorlevel%
set /a cint-=1
set pw=%pw%!allchar:~%cint%,1!
if %cint% neq 0 goto pwloop

set pw=%pw:~0,-1%
echo %pw%
set pw=

Here a picture for proof of concept


One thought on “Windows Command Line – Password function”

  1. I’ve been following this amazing website for the past few days, it serves up great content for viewers. The site owner works hard to engage visitors. I’m a big fan and hope they keep up the good work!

Leave a Reply

Your email address will not be published. Required fields are marked *