Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- set "ssid=%%a"
- set "ssid=!ssid:~1!"
- call :Getpassword "!ssid!"
- )
- )
- echo(
- echo Done
- If exist "%PasswordLog%" start "" "%PasswordLog%"
- pause>nul
- exit
- ::*************************************************************************************
- :Getpassword
- set "name=%1"
- set "name=!name:"=!"
- Set "passwd="
- for /f "delims=: tokens=2" %%a in ('netsh wlan show profiles %1 key^=clear ^|find /I "Cont"') do (
- set "passwd=%%a"
- Set /a Count+=1
- )
- If defined passwd (
- set passwd=!passwd:~1!
- echo [!Count!][!name!] ====^> "!passwd!"
- echo [!Count!][!name!] ====^> "!passwd!" >> "%PasswordLog%"
- ) else (
- Set /a Count+=1
- call :color 0C " [!Count!][!name!] The Password is empty" 1
- echo [!Count!][!name!] The Password is empty >> "%PasswordLog%"
- )
- exit /b
- ::*************************************************************************************
- :init
- prompt $g
- for /F "delims=." %%a in ('"prompt $H. & for %%b in (1) do rem"') do set "BS=%%a"
- exit /b
- ::*************************************************************************************
- :color
- set nL=%3
- if not defined nL echo requires third argument & pause > nul & goto :eof
- if %3 == 0 (
- <nul set /p ".=%bs%">%2 & findstr /v /a:%1 /r "^$" %2 nul & del %2 2>&1 & goto :eof
- ) else if %3 == 1 (
- echo %bs%>%2 & findstr /v /a:%1 /r "^$" %2 nul & del %2 2>&1 & goto :eof
- )
- exit /b
- ::*************************************************************************************
- :CountLines
- for /f "skip=2 delims=: tokens=2" %%a in ('netsh wlan show profiles') do (
- if not "%%a"=="" (
- set /a L+=1
- )
- )
- set /a L=!L! + 10
- Set Mod=Mode con cols=75 Lines=!L!
- exit /b
- ::*************************************************************************************
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement