justcallmekoko / ESP32Marauder

A suite of WiFi/Bluetooth offensive and defensive tools for the ESP32
6.19k stars 648 forks source link

pcap files are broken at "_flipper_sd_serial" firmware #347

Closed RekordNadoev closed 1 year ago

RekordNadoev commented 1 year ago

Hardware: Flipper Zero dev-board (ESP32-S2) with *_flipper_sd_serial.bin firmware

Software: Flipper Zero Marauder companion v0.6.2 Saving .pcap files to Flipper's SD-card.

Saved .pcap files are broken after "esp32_marauder_v0_10_8_20230621_flipper_sd_serial.bin" firmware.

Open with tcpdump v4.99.1: "tcpdump: unknown file format" Open with wireshark v3.6.2: "The file "sniffpmkid_0.pcap" appears to be damaged or corrupt (commview: NCFX data negth 0 < 20)" Open with aircrack-ng v1.7: "Unsupported file format (not a pcap or IVs file)."

Tried firmwares: esp32_marauder_v0_10_8_20230621_flipper_sd_serial.bin - OK esp32_marauder_v0_11_0_rc3_20230727_flipper_sd_serial.bin - .pcap is broken esp32_marauder_v0_11_1_20230907_flipper_sd_serial.bin - .pcap is broken esp32_marauder_v0_12_0_20230910_flipper_sd_serial.bin - .pcap is broken esp32_marauder_v0_12_1_20231005_flipper_sd_serial.bin - .pcap is broken

To Reproduce Steps to reproduce the behavior:

  1. Get Flipper Zero with dev-board + ESP32 Marauder firmware
  2. Run Apps => GPIO => [ESP32] WiFi Marauder
  3. Set "Save to flipper sdcard" to "Yes" for logs and pcaps
  4. Run Sniff => pmkid (or Sniff => raw) => get .pcap files saved to flipper's sdcard
  5. Copy .pcap files to PC and try to open with wireshark/tcpdump/aircrack-ng
  6. Get error messages. tcpdump: "tcpdump: unknown file format"; wireshark: "The file "sniffpmkid_0.pcap" appears to be damaged or corrupt (commview: NCFX data negth 0 < 20)"; aircrack-ng: "Unsupported file format (not a pcap or IVs file)."

Expected behavior Steps 1-5 are the same.

  1. .pcap files opening OK with wireshark/tcpdump/aircrack-ng.

Marauder (please complete the following information if applicable):

Additional context Last tried version with correct .pcap files was esp32_marauder_v0_10_8_20230621_flipper_sd_serial.bin

thinkjk commented 1 year ago

I'm having the same issues, I've tried a few fixes from reddit and none of worked. I'm using the official dev board.

I'm running the latest unleashed (63) and using FZEasyMarauderFlash (with option 2) to flash

justcallmekoko commented 1 year ago

Have you tried this with the non serial SD version of the firmware and saving directly to an SD card connected to the ESP32?

RekordNadoev commented 1 year ago

No unfortunately. I've original FlipperZero dev-board with no SD only. All i can tell: esp32_marauder_v0_10_8_20230621_flipper_sd_serial.bin does work, newer versions does not.

RekordNadoev commented 1 year ago

Found ESP32 Marauder v6 hardware with SD and checked:

So the problem is in flipper_sd_serial after v0_10_8

What additional info should i provide to help debug?

thinkjk commented 1 year ago

ESP32 Marauder v6

I'm happy to help test on my dev board as well. and as @RekordNadoev mentioned there is no SD slot on the board by default.

justcallmekoko commented 1 year ago

I am currently working on a solution. The issue first appears in v0.11.0 and I've found it's cause. This will be fixed in v0.13.1

RekordNadoev commented 1 year ago

Thank you for great job!

justcallmekoko commented 1 year ago

All set https://github.com/justcallmekoko/ESP32Marauder/releases/tag/v0.13.1

thinkjk commented 1 year ago

All set https://github.com/justcallmekoko/ESP32Marauder/releases/tag/v0.13.1

Confirmed it's working for me now. Thanks @justcallmekoko!

Ralhazrolex commented 10 months ago

updated to v0.13.1 and still pcaps are zero bytes, what could I be missing?

eaudaim commented 6 months ago

Hi ! Same here, updated to version 0.13.10 with fzeeflasher, and still have 0 bytes files.

Hardware is a flipper zero and esp-wroom-32.

When the marauder find the good channel (even on the "targeted active" mode, it failed to aim the selected acces point almost everytime), the flipper display this text : flipperCreen

Screenshot-20240525-185908

But the files "sniffpmkid_XXX.txt" stay empty... :/

PS : Wiring is like this :

Esp32 RXD => TX Flipper zero

ESP32 TXD => RX Flipper zero

ESP32 3v3 to 3v3 Flipper zero pin

Esp32 GND pin to GND Flipper zero pin

RekordNadoev commented 6 months ago

Tried ESP32-wroom-32 with esp32_marauder_v0_13_10_20240425_esp32_lddb firmware and Marauder companion v0.71. It just worked.

Did You turn on "Save to flipper sdcard" in the app?

eaudaim commented 6 months ago

Yes sir !

eaudaim commented 6 months ago

Can you explain me in detail the procedure you followed to make it work ? Did you flashed with FzeeFlasher or another tool like ArduinoIDE or something else ?

Did you wired it the same way i did ?

RekordNadoev commented 5 months ago

Yes, wired it the same way.

I use unleashed firmware dev branch.

RekordNadoev commented 5 months ago

Missed one step in my previous message.

After "in "ESP Flasher" app slect "Quick Flash" => "ESP32-WROOM"" (bootloader)

eaudaim commented 3 weeks ago

I forgot to try your aswer for almost 5 month, but today i came back to this problem and your solution worked perfectly.

I noticed that with other techniques (fzeeflasher for example) marauder had various problems, and especially it did not stop once the sniff was launched, even when going back in the menus, and it created several PCAP files, I think the problem came from corrupted PCAP files because I had to reboot the board to stop the sniff.

What I find strange is that the first time I used the flipper application to flash the esp, some problems were there, others not, and I don't remember if the files were empty but i think it was.

Anyway, thank you very much for your help :)