Skip to main content

Posts

Showing posts from March, 2026

How a Single `while(1)` Bricked My ESP32-S3 — and What I Learned Fixing It

    This is a custom ESP32S3 prototyping board i built to troubleshoot the issues.  It Started With a Simple Problem I was testing the EvilCrow Cable Wind — a USB HID device built around the ESP32-S3 that executes keystroke injection payloads over WiFi. Everything seemed fine: the keyboard HID was typing correctly, the web interface loaded, basic commands like RunWin worked. But ServerConnect and ShellWin did absolutely nothing. No error. No feedback. Just silence. Digging Into the Code The first thing I found was this pattern — repeated across four commands: ORIGINAL — DANGEROUS if (!clientServer.connect(serverIP, serverPort)) { while(1); // hangs forever if TCP fails } ⚠ Critical Bug If TCP connection failed for any reason, the device entered an infinite loop with no timeout, no error output, and no recovery path. Ever. But there was more. The bugs were stacking: critical   TCP failures were environmental: listene...

How a Single `while(1)` Bricked My ESP32-S3 — and What I Learned Fixing It

    This is a custom ESP32S3 prototyping board i built to troubleshoot the issues.  It Started With a Simple Problem I was testing the EvilCrow Cable Wind — a USB HID device built around the ESP32-S3 that executes keystroke injection payloads over WiFi. Everything seemed fine: the keyboard HID was typing correctly, the web interface loaded, basic commands like RunWin worked. But ServerConnect and ShellWin did absolutely nothing. No error. No feedback. Just silence. Digging Into the Code The first thing I found was this pattern — repeated across four commands: ORIGINAL — DANGEROUS if (!clientServer.connect(serverIP, serverPort)) { while(1); // hangs forever if TCP fails } ⚠ Critical Bug If TCP connection failed for any reason, the device entered an infinite loop with no timeout, no error output, and no recovery path. Ever. But there was more. The bugs were stacking: critical   TCP failures were environmental: listene...