Quiz Entry - updated: 2026.12.01
Which ESP32 features stop an attacker with physical access from reading or changing the firmware, and what does each one do?
Disabling JTAG closes the debug port, flash encryption makes the flash contents unreadable off the chip, and Secure Boot refuses to run firmware that isn't signed with the vendor's key. They are enabled through one-time eFuses and are meant to be used together.
* One protection per path, which is why they ship together. *
| Feature | Protects against | How |
|---|---|---|
| JTAG disable (eFuse) | Halting and inspecting the CPU through the debug port | A one-time bit switches the port off; ESP-IDF burns it when flash encryption or Secure Boot is enabled |
| Flash encryption | Reading the firmware and data by dumping the flash chip | Flash is encrypted with a key held in eFuses that software cannot read back |
| Secure Boot | Flashing modified or foreign firmware | The bootloader verifies each image's signature before running it |
| Disabling the ROM download mode (or using its secure mode) | Using the serial bootloader to read or write flash | eFuse setting that restricts the UART download commands |
None of them is enough on its own: encryption without Secure Boot still lets an attacker flash their own code, and Secure Boot without encryption still lets them read secrets. eFuses cannot be undone, so these features are switched on for production units only, after development is finished.
Go deeper:
ESP-IDF — Security Overview — how flash encryption, Secure Boot and JTAG disabling fit together.
ESP-IDF — Flash Encryption — what is burned on first boot.
ESP-IDF — Secure Boot v2 — signed images and the boot chain.