Skip to content

Embedded Security Overview

A high-level view of common embedded security controls, trust boundaries, and update risks.

This English edition keeps the original illustrations and reproducible command or configuration examples.

Commands and configuration

芯片内部 ROM(出厂固化,不可修改)
        ↓ 验证签名
    Bootloader(厂商签名)
        ↓ 验证签名
    Linux Kernel(厂商签名)
        ↓ 验证签名
    Root Filesystem(厂商签名)
// 开发图方便关掉验证,量产忘了开回来
// 这等于 TLS 完全没用
mbedtls_ssl_conf_authmode(&conf, MBEDTLS_SSL_VERIFY_NONE);
开发者用私钥对固件签名
        ↓
固件包(含签名)上传服务器
        ↓
设备通过加密通道下载
        ↓
用内置公钥验证签名
        ↓
验证通过 → 写入存储 → 重启
验证失败 → 丢弃,保持原固件不变
正在运行:A 分区
         ↓
下载新固件 → 写入 B 分区
         ↓
验证签名通过 → 重启从 B 启动
         ↓
启动成功 → B 成为当前分区
启动失败 → 自动回滚 A 分区
威胁类型              对应防线
──────────────────────────────────
刷入恶意固件    →    Secure Boot
拆机读取数据    →    存储加密
窃听篡改通信    →    TLS 加密通信
伪造 OTA 包     →    签名验证

Practical notes

Test each change on a recoverable target, keep logs from the boot or failure path, and record the exact kernel and userspace versions used in the result.