Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
bmorcelli authored May 25, 2024
2 parents 437e220 + 5749e19 commit dc86cf0
Show file tree
Hide file tree
Showing 7 changed files with 367 additions and 97 deletions.
53 changes: 33 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,36 @@
# Bruce_new
- [ ] Readme
- [ ] Purpose
- [ ] List of Features
- [ ] How to Install
- [ ] Web Flasher
- [ ] How to Build
- [ ] Wiki
- [ ] WiFi
- [ ] BLE
- [ ] RF
- [ ] RFID
- [ ] Others
# Bruce

Bruce is meant to be a versatile ESP32 firmware that supports a ton of offensive features focusing to facilitate on Red Team operations.
It also supports m5stack products and works great with Cardputer and sticks.

# How to install
## For m5stack devices
The easiest way to install Bruce is if you already use M5Launcher to manage your m5stack device, you can install it with OTA

Or you can burn it directly from the [m5burner tool](https://docs.m5stack.com/en/download), just search for 'Bruce' on the device category you want to and click on burn

# List of Functionalities
- [x] Boot Screen
- [ ] Code Organization
Alternatively you can also download the binary from releases and flash locally using esptool.py
```sh
esptool.py --port /dev/ttyACM0 write_flash 0x00000 Bruce.bin
```
or use a web flasher like https://web.esphome.io/

# Wiki
For more information on each function supported by Bruce, [read our wiki here](https://example.com).

# List of Features

## WiFi
- [x] Connect to WiFi (New)
- [x] WiFi AP (New)
- [x] Disconnect WiFi (New)
- [X] WiFi Atks
- [x] Information
- [X] Target Deauth
- [ ] Deauth Flood
- [X] EvilPortal + Deauth
- [x] Beacon Spam
- [x] Target Atk
- [x] Information
- [X] Target Deauth
- [X] EvilPortal + Deauth
- [ ] Deauth Flood (More than one target)
- [X] TelNet
- [X] SSH
- [x] RAW Sniffer
Expand Down Expand Up @@ -71,4 +76,12 @@
- [ ] Clock (New)
- [x] Restart

# TODO
- [ ] Wiki
- [ ] WiFi
- [ ] BLE
- [ ] RF
- [ ] RFID
- [ ] Others


103 changes: 50 additions & 53 deletions src/display.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -258,38 +258,35 @@ void drawMainMenu(int index) {

const char* texts[6] = { "WiFi", "BLE", "RF", "RFID", "Others", "Config" };

draw.deleteSprite();
draw.createSprite(80,80);
drawMainBorder();
tft.setTextSize(FG);

switch(index) {
case 0:
drawWifi();
drawWifi(80,27);
break;
case 1:
drawBLE();
drawBLE(80,27);
break;
case 2:
drawRf();
drawRf(80,27);
break;
case 3:
drawRfid();
drawRfid(80,27);
break;
case 4:
drawOther();
drawOther(80,27);
break;
case 5:
drawCfg();
drawCfg(80,27);
break;
}
tft.setTextSize(FM);
tft.drawCentreString(texts[index],tft.width()/2, tft.height()-(LH*FM+10), SMOOTH_FONT);
tft.setTextSize(FG);
tft.drawChar('<',10,tft.height()/2+10);
tft.drawChar('>',tft.width()-(LW*FG+10),tft.height()/2+10);
draw.pushSprite(80,27);
draw.deleteSprite();


}

Expand Down Expand Up @@ -418,11 +415,11 @@ void drawWifiSmall(int x, int y) {
draw.deleteSprite();
}

void drawWifi() {
draw.fillSprite(BGCOLOR);
draw.fillCircle(40,60,6,FGCOLOR);
draw.drawSmoothArc(40,60,26,20,130,230,FGCOLOR, BGCOLOR,true);
draw.drawSmoothArc(40,60,46,40,130,230,FGCOLOR, BGCOLOR,true);
void drawWifi(int x, int y) {
tft.fillRect(x,y,80,80,BGCOLOR);
tft.fillCircle(40+x,60+y,6,FGCOLOR);
tft.drawSmoothArc(40+x,60+y,26,20,130,230,FGCOLOR, BGCOLOR,true);
tft.drawSmoothArc(40+x,60+y,46,40,130,230,FGCOLOR, BGCOLOR,true);
}

void drawBLESmall(int x, int y) {
Expand All @@ -439,54 +436,54 @@ void drawBLESmall(int x, int y) {
draw.deleteSprite();
}

void drawBLE() {
draw.fillSprite(BGCOLOR);
draw.drawWideLine(40,53,2,26,5,FGCOLOR,BGCOLOR);
draw.drawWideLine(40,26,2,53,5,FGCOLOR,BGCOLOR);
draw.fillTriangle(40,26,20,40,20,12,FGCOLOR);
draw.fillTriangle(40,53,20,40,20,68,FGCOLOR);
draw.drawArc(40,40,10,12,210,330,FGCOLOR,BGCOLOR);
draw.drawArc(40,40,23,25,210,330,FGCOLOR,BGCOLOR);
draw.drawArc(40,40,36,38,210,330,FGCOLOR,BGCOLOR);
void drawBLE(int x, int y) {
tft.fillRect(x,y,80,80,BGCOLOR);
tft.drawWideLine(40+x,53+y,2+x,26+y,5,FGCOLOR,BGCOLOR);
tft.drawWideLine(40+x,26+y,2+x,53+y,5,FGCOLOR,BGCOLOR);
tft.fillTriangle(40+x,26+y,20+x,40+y,20+x,12+y,FGCOLOR);
tft.fillTriangle(40+x,53+y,20+x,40+y,20+x,68+y,FGCOLOR);
tft.drawArc(40+x,40+y,10,12,210,330,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,40+y,23,25,210,330,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,40+y,36,38,210,330,FGCOLOR,BGCOLOR);
}

void drawCfg() {
draw.fillSprite(BGCOLOR);
void drawCfg(int x, int y) {
tft.fillRect(x,y,80,80,BGCOLOR);
int i=0;
for(i=0;i<6;i++) {
draw.drawArc(40,40,30,20,15+60*i,45+60*i,FGCOLOR,BGCOLOR,true);
tft.drawArc(40+x,40+y,30,20,15+60*i,45+60*i,FGCOLOR,BGCOLOR,true);
}
draw.drawArc(40,40,22,8,0,360,FGCOLOR,BGCOLOR,false);
tft.drawArc(40+x,40+y,22,8,0,360,FGCOLOR,BGCOLOR,false);
}

void drawRf() {
draw.fillSprite(BGCOLOR);
draw.fillCircle(40,30,7,FGCOLOR);
draw.fillTriangle(40,40,25,70,55,70,FGCOLOR);
draw.drawArc(40,30,18,15,40,140,FGCOLOR,BGCOLOR);
draw.drawArc(40,30,28,25,40,140,FGCOLOR,BGCOLOR);
draw.drawArc(40,30,38,35,40,140,FGCOLOR,BGCOLOR);
draw.drawArc(40,30,18,15,220,320,FGCOLOR,BGCOLOR);
draw.drawArc(40,30,28,25,220,320,FGCOLOR,BGCOLOR);
draw.drawArc(40,30,38,35,220,320,FGCOLOR,BGCOLOR);
void drawRf(int x, int y) {
tft.fillRect(x,y,80,80,BGCOLOR);
tft.fillCircle(40+x,30+y,7,FGCOLOR);
tft.fillTriangle(40+x,40+y,25+x,70+y,55+x,70+y,FGCOLOR);
tft.drawArc(40+x,30+y,18,15,40,140,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,30+y,28,25,40,140,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,30+y,38,35,40,140,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,30+y,18,15,220,320,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,30+y,28,25,220,320,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,30+y,38,35,220,320,FGCOLOR,BGCOLOR);
}

void drawRfid() {
draw.fillSprite(BGCOLOR);
draw.drawRoundRect(5,5,70,70,10,FGCOLOR);
draw.fillRect(0,40,40,40,BGCOLOR);
draw.drawCircle(15,65,7,FGCOLOR);
draw.drawArc(15,65,18,15,180,270,FGCOLOR,BGCOLOR);
draw.drawArc(15,65,28,25,180,270,FGCOLOR,BGCOLOR);
draw.drawArc(15,65,38,35,180,270,FGCOLOR,BGCOLOR);
void drawRfid(int x, int y) {
tft.fillRect(x,y,80,80,BGCOLOR);
tft.drawRoundRect(5+x,5+y,70,70,10,FGCOLOR);
tft.fillRect(0+x,40+y,40,40,BGCOLOR);
tft.drawCircle(15+x,65+y,7,FGCOLOR);
tft.drawArc(15+x,65+y,18,15,180,270,FGCOLOR,BGCOLOR);
tft.drawArc(15+x,65+y,28,25,180,270,FGCOLOR,BGCOLOR);
tft.drawArc(15+x,65+y,38,35,180,270,FGCOLOR,BGCOLOR);
}

void drawOther() {
draw.fillSprite(BGCOLOR);
draw.fillCircle(40,40,7,FGCOLOR);
draw.drawArc(40,40,18,15,0,340,FGCOLOR,BGCOLOR);
draw.drawArc(40,40,25,22,20,360,FGCOLOR,BGCOLOR);
draw.drawArc(40,40,32,29,0,200,FGCOLOR,BGCOLOR);
draw.drawArc(40,40,32,29,240,360,FGCOLOR,BGCOLOR);
void drawOther(int x, int y) {
tft.fillRect(x,y,80,80,BGCOLOR);
tft.fillCircle(40+x,40+y,7,FGCOLOR);
tft.drawArc(40+x,40+y,18,15,0,340,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,40+y,25,22,20,360,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,40+y,32,29,0,200,FGCOLOR,BGCOLOR);
tft.drawArc(40+x,40+y,32,29,240,360,FGCOLOR,BGCOLOR);
}

12 changes: 6 additions & 6 deletions src/display.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,19 @@ void drawBatteryStatus();

void drawWifiSmall(int x, int y);

void drawWifi();
void drawWifi(int x, int y);

void drawBLESmall(int x, int y);

void drawBLE();
void drawBLE(int x, int y);

void drawRf();
void drawRf(int x, int y);

void drawRfid();
void drawRfid(int x, int y);

void drawOther();
void drawOther(int x, int y);

void drawCfg();
void drawCfg(int x, int y);



Expand Down
2 changes: 1 addition & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ void loop() {
options.push_back({"Raw Sniffer", [=]() { sniffer_setup(); }});
options.push_back({"DPWO-ESP32", [=]() { dpwo_setup(); }});
options.push_back({"Evil Portal", [=]() { startEvilPortal(); }});
options.push_back({"Scan Hosts", [=]() { local_scan_setup(); }});
options.push_back({"Scan Hosts", [=]() { local_net_scan_setup(); }});
options.push_back({"Wireguard", [=]() { wg_setup(); }});
options.push_back({"Main Menu", [=]() { backToMenu(); }});
delay(200);
Expand Down
2 changes: 1 addition & 1 deletion src/mykeyboard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ String keyboard(String mytext, int maxSize, String msg) {
/* When Select a key in keyboard */
#if defined (CARDPUTER)
Keyboard.update();
if (Keyboard.isChange()) {
if (Keyboard.isPressed()) {
Keyboard_Class::KeysState status = Keyboard.keysState();
for (auto i : status.word) {
mytext += i;
Expand Down
Loading

0 comments on commit dc86cf0

Please sign in to comment.