Embedded systems and security roadmap

A suggested order for learning embedded systems and their security, from the microcontroller up to attacks on hardware.

Each stage lists what to learn and one or two public places to learn it. The topics on this site follow the same subjects.

1. Microcontroller basics

Write C for a microcontroller, read a reference manual, and use a debugger: breakpoints, memory and register views.

  • Interrupt: practical articles on firmware development

2. Know the processor

Learn the Cortex-M exception model, stack frames, privilege levels, the MPU, and how to read a fault.

3. Real-time operating systems

Understand tasks, scheduling, context switches and synchronisation, and how an RTOS uses the MPU to separate tasks.

  • FreeRTOS: documentation and source code you can read
  • ThreadX: the source code, now an Eclipse project

4. Secure C and C++

Learn the rules that keep embedded code predictable: integer and pointer safety, bounds, undefined behaviour, and coding standards.

5. FPGA and digital design

Learn how an FPGA is built, how to describe hardware in an HDL, and how to meet timing.

  • Nandland: tutorials on FPGA basics, VHDL and Verilog

6. Verification

Write a verification plan, build testbenches, and measure coverage. For security, plan how each protection will be shown to work.

  • cocotb: testbenches for HDL designs written in Python

7. Platform security features

Study secure boot and the chain of trust, TrustZone for Armv8-M, debug protection and key storage.

8. Attacks on hardware

Read Arm assembly and analyse firmware without its source code. Extract firmware through debug ports and external flash, then move on to fault injection and side-channel analysis.

  • Azeria Labs: free tutorials on Arm assembly and exploitation
  • VoidStar Security: guides to building a hardware lab and to hardware hacking
  • ChipWhisperer: open tools and tutorials for fault injection and power analysis

9. Practice

Build small projects on real boards, take part in capture-the-flag events with embedded targets, and write up what you learn. Test only hardware you own or are allowed to test.