Lesson 5 of 13 · 15m
UART: The Console They Forgot to Disable
Nearly every embedded board still exposes a TTL serial console; finding it takes a multimeter, and what it prints decides the rest of the audit.
The port that is always there
Pop the case on a router, camera, or IP KVM and within arm's reach of the SoC there is a row of three or four pads — usually a stripped header labelled J1, sometimes unlabeled entirely. That is the UART: TTL-level transmit and receive, the console the bootloader and kernel were built to talk to. It is almost never disabled on production hardware because it is the factory's own diagnostic path.
Finding the pins takes five minutes. GND is confirmed by continuity to a shield can or the PSU ground. TX announces itself: it idles high at 3.3 V (or 1.8 V on newer silicon — measure before you wire a 3.3 V adapter to it) and toggles hard the instant power lands, because the boot ROM starts printing immediately. RX sits beside it, usually pulled high and quiet. What remains is voltage and baud rate. A logic analyzer on TX shows the shortest pulse width; 115200 8N1 covers most boards, with 57600, 38400, and 9600 as the runners-up. Then picocom -b 115200 /dev/ttyUSB0 (or screen), cross TX to RX, and power the board. One wiring rule saves boards: connect TX, RX, GND only — never the VCC pad, which back-feeds the logic and can cook a rail. Garbage on screen is almost always wrong baud, not encryption: sweep the common rates before assuming anything exotic.
What comes out is the machine's autobiography: boot ROM version, SPL, the U-Boot build and its environment, kernel cmdline, MTD partition table as it is created (Creating 7 MTD partitions), memory map, MAC addresses — and on a depressing fraction of consumer devices, the Wi-Fi PSK or an admin password, printed in cleartext because nobody considered the console a public interface. It is. Anyone holding a $3 USB-serial adapter is reading it. Some boards multiplex the UART onto GPIO pins shared with other functions, and some kernels stay silent until a late console= — absence of spew at first power-on is not proof of absence; keep probing the pads through the whole boot. And when the spew ends in a login prompt, take it seriously: plenty of consumer gear runs a getty on ttyS0 behind credentials printed in the manual — or behind the same factory pairs Mirai later typed into telnet.
The wrong mental model
"There's no console on this device" — meaning no socket on the outside. The console is a firmware feature; the header is a courtesy. Boards ship with console=ttyS0 compiled into the cmdline and four empty pads inside the case. Conversely, vendors who do try to hide it stop at the header — the UART is still inside the SoC doing its job. The port is not the secret. What it prints is.
The deeper wrong assumption is that the console is read-only. U-Boot prints Hit any key to stop autoboot: and means it — send a byte and you have a bootloader shell with printenv, sf probe, nand read, and memory dump commands. From there setenv bootargs ... init=/bin/sh and the next boot is a root shell on the real filesystem. The SerComm backdoor found on Linksys/Netgear gear in 2014 (TCP 32764, unauthenticated scfgmgr shell) did not need UART — but UART was how researchers got inside the firmware to look.
What to actually do
On the audit side: probe pads before anything invasive, respect the logic level, and capture the full boot log verbatim (picocom -b 115200 -g boot.log logs the session) — it names the flash layout, the U-Boot version, the partition offsets the rootfs teardown lesson depends on, the update URL in some cases, and every credential the firmware decided to leak.
On the shipping side: treat console output as public data. Build production images with console= removed or pointing nowhere reachable, set U-Boot bootdelay=-2 so autoboot cannot be aborted, disable UART in the production device tree where the design allows, and never let a password, key, or provisioning URL appear in a boot log. If the factory needs diagnostics, gate them behind a test-mode fuse, not a header you hope nobody finds.
Was this lesson helpful?
Keep reading
Related articles from the SudoSecurity blog.
Januscape: A 16-Year-Old Linux KVM Escape Bug
CVE-2026-53359 lets a guest VM crash or potentially root your Proxmox host, and it hid in KVM's shared code for 16 years. What to patch and how to check.
The CPU-ocalypse Is Here, and the AI Industry Walked Right Into It
For three years the AI industry watched GPUs. Nobody was watching the CPU. Now Intel is warning of six-month lead times, AMD has blown past expectations, and the chip everyone assumed would always be available has become the new bottleneck in the biggest infrastructure buildout since the internet.
The RAMpocalypse! How AI Companies Are Destroying the Hosting Industry and Your Wallet
How AI infrastructure demand is driving up VPS and dedicated server costs — and why your hosting bill is going up even though you haven't changed anything.
Getting Started with Embedded C
The Goal By the end of this tutorial, you will be able to compile a binary written for the avr instruction set targeting the AtMega328P microcontroller on an Arduino Nano or Arduino Uno R3 form factor. Needed Documentation * Arduino Nano PCB design * Atmega328P datasheet Materials used * Arduino Nano * Arduino Uno R3 * Relevant cable * Computer Software Used * make (for easy of compiling and building) * avr-gcc (our compiler for avr ISA) * binutils-avr * avr-libc * avrdude (