Skip to content
This repository has been archived by the owner on Aug 22, 2024. It is now read-only.

Adding BadUSB with payloads and layouts #134

Closed
wants to merge 46 commits into from

Conversation

usg-ishimura
Copy link

Created Bad USB functionality with tested layouts and payloads.
Tried to build from source with arduino-cli, arduino IDE and docker and it seems to work.
Not tested on M5StickC only M5Cardputer.
I chose to use esp32 USB library so that it can be used in conjunction with WiFi AP to exfiltrate data (see the first payload).

@n0xa
Copy link
Owner

n0xa commented Mar 25, 2024

I need to test what you've built, but I'll probably request a fresh PR no matter what since you've got 40+ commits here.

I know 100% the StickC and StickC Plus do not support BadUSB at all. The ESP32S2 in the Cardputer does. I don't know if the StickCPlus2 can do it but I suspect not. You will need to use ifdef to lock this to the cardputer platform only at the very least. I'll try to test what you've got so far sometime this week but I'm still unpacking from the move and haven't set up my Arduino development laptop yet.

@usg-ishimura
Copy link
Author

I squashed the commits on my own develop branch and added one last commit that generates Bad USB entry in main menu only if CARDPUTER is defined,
I'll wait for feedback to open the new PR.

@usg-ishimura
Copy link
Author

@n0xa any update on this PR?

@n0xa
Copy link
Owner

n0xa commented Apr 16, 2024

Sorry, it's been a crazy 2 months or so full of uncertainty and I've had to focus on work, construction at our new place, and family/medical things. Also, my main laptop that I do all of my ESP32 work on is stuck in some kind of upgrade dependency purgatory at the moment, so my toolchain for Arduino/M5Stack is kind of a mess as well. I'll try to compile and test this in the next few days.

@usg-ishimura
Copy link
Author

ok, no rush for me, just wanted to check

@n0xa
Copy link
Owner

n0xa commented Apr 19, 2024

I'm trying it out this morning, but this fork will not compile cleanly on my M5Sticks. You'll have to further gate pretty much anything to do with USBHID using ifdefs so they only are included when CARDPUTER is defined.

@usg-ishimura
Copy link
Author

Should be fixed now, I put all references to USBHID in ifdef CARDPUTER condition blocks on m5stick-nemo.ino and tried to compile for M5StickC, it's up to date on both my main and develop branch

@n0xa n0xa closed this Aug 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants