MCUboot — Secure Bootloader for Microcontrollers
MCUboot is an open-source, hardware-independent secure bootloader for 32-bit microcontrollers. It can serve as the root of trust at the firmware level when it is stored immutably (ROM or write-protected flash) together with its public key; it then verifies that firmware images are cryptographically signed and authentic before running them. MCUboot is the de facto bootloader for Zephyr RTOS and is increasingly used to support CRA compliance.
Why MCUboot Matters
Without a secure bootloader, anyone with physical or remote access can flash modified firmware onto a device — bypassing all software security. MCUboot prevents this by:
- Verifying signatures before executing any firmware image
- Managing firmware slots for safe over-the-air (OTA) updates
- Rolling back to a known-good image if a new update fails
- Encrypting update images in transit and in the secondary slot, which hinders reverse engineering of the update file
Key Features
| Feature | Description |
|---|---|
| Image signing | Ed25519, ECDSA-P256, RSA-2048/3072 signature verification |
| Encrypted images | AES-CTR-128/256 encryption of the image in transit and in the secondary slot (e.g. external flash); it is decrypted when installed to the primary slot |
| Dual-slot update | Primary + secondary slot for fail-safe firmware swaps |
| Swap upgrades | Resumable image swap (swap using offset, move or scratch) — survives power loss mid-update |
| Rollback protection | Optional downgrade prevention: version comparison (overwrite-only mode) or a security counter checked against a counter in trusted non-volatile storage |
| Serial recovery | MCUmgr protocol for USB/UART recovery if OTA fails |
| Measured boot | Boot record (image hash, version, signer ID) passed to the runtime firmware, e.g. for an attestation service |
Update Modes
| Mode | Mechanism | Power-Loss Safe | Flash Wear |
|---|---|---|---|
| Swap (scratch) | Sector swap through a scratch area; no longer recommended by the project | ✅ Resumable | Higher |
| Swap (move) | In-place sector shuffling (no scratch area) | ✅ Resumable | Medium |
| Swap (offset) | Swap through one spare sector in the secondary slot (no scratch area); the swap mode the project prefers | ✅ Resumable | Low |
| Overwrite-only | Direct overwrite of primary slot; no revert to the previous image | ✅ Copy is redone | Lowest |
| Direct XIP | Execute from either slot (no copy) | ✅ | None |
Supported Platforms
MCUboot is OS and hardware independent. It supports:
- RTOS: Zephyr, FreeRTOS (through vendor SDKs, e.g. NXP MCUXpresso), Apache NuttX, Apache Mynewt, Mbed OS (no longer maintained by Arm since July 2026), RIOT (boot target only)
- Vendors: Nordic (nRF52/53/91), STMicroelectronics (STM32L5, STM32U5, STM32H5), NXP (LPC, i.MX RT), Espressif (ESP32), Infineon/Cypress (PSoC 6)
- Architectures: ARM Cortex-M, RISC-V, Xtensa
CRA Compliance Connection
The EU Cyber Resilience Act sets outcome-based requirements (Annex I) that MCUboot can help meet:
- ✅ Integrity protection and secure distribution of updates — MCUboot supports this via image signing
- ✅ Rollback protection — not named in the CRA, but a common control against reinstalling vulnerable firmware; MCUboot can enforce it with a security counter in each image (optional)
- ✅ Timely security updates as part of vulnerability handling — MCUboot enables patch deployment via OTA
Related Terms
- Secure Boot — The broader concept of verified boot chains; MCUboot is the implementation layer for MCU-based systems.
- OTA Update — MCUboot manages the firmware slot swapping that makes secure OTA possible.
- CRA — EU regulation setting outcome-based cybersecurity requirements for products with digital elements, including integrity protection and secure distribution of security updates.
In embedded development projects we use MCUboot wherever the platform supports it — with secure boot and OTA updates designed to the CRA requirements from day one. See our Embedded Security & IoT capabilities.
Official References
- MCUboot — open-source secure bootloader — MCUboot project (official documentation)
- Regulation (EU) 2024/2847 (CRA) — Annex I, essential cybersecurity requirements — EUR-Lex