Secure Boot Components
The following components, which were not used in the Boot Sequence article, appear
- Security Engine
- Component where the internal cryptographic engine and its keys are stored
- See this article
PKH (Public Key Hash), SBK (Secure Boot Key), and DK (Device Key) are written to Fuse in advance. See details about SBK and DK: https://docs.nvidia.com/jetson/archives/l4t-archived/l4t-3261/index.html#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide/bootloader_secure_boot.html#wwpID0E0BI0HA
The use of SBK and DK in Jetson Nano is not supported, so the explanation of SBK and DK here is for reference only.
Start from ROM
When power is ON, BPMP fetches the ROM and starts executing the program.
In terms of Secure Boot, ROM is always secure because it cannot be updated. In other words, if ROM has a bug, it cannot be updated, so ROM development must be carefully designed and implemented.
Load BCT, store PK to SE, and validate BCT
ROM loads BCT from On board flash into SysRAM.
ROM compares the hash value of the PK (Public Key) in the BCT with the PKH in the Fuse.
ROM stores the PK in SE if the hash value of the PK and PKH match.
The following descriptions of SBK, DK, and SSK are for reference only. SBK, DK, and SSK are not supported by Jetson Nano.
ROM stores SBK of Fuse in SE, derives SSK from SBK, DK and UID, and stores SSK in SE. How to derive SSK is unknown.
ROM verifies the BCT’s sign with PK in SE.
Load and validate TegraBoot
ROM loads TegraBoot from on board flash into SysRAM.
ROM verifies TegraBoot’s sign with PK in SE.
Jump to TegraBoot
ROM transitions to TegraBoot on SysRAM.
Load and validate TOS and CBoot
TegraBoot loads TOS and CBoot from on board flash into SDRAM.
TegraBoot verifies TOS sign with SE PK and CBoot sign with PK in SE.
Jump to TOS
TegraBoot starts the CPU, and the started CPU fetches the TOS on SDRAM and starts executing the program.
Jump to CBoot
TOS exits the Trust Zone and transitions to CBoot on SysRAM.
Load and validate u-boot
CBoot loads u-boot from on board flash into SDRAM and verifies u-boot’s sign with CBoot’s PK.
Need to investigate if u-boot is properly verified by CBoot.
Jump to u-boot
CBoot transitions to u-boot on SDRAM.
Secure Boot provided by Nvidia ends here. u-boot verification of initrd and kernel needs to be implemented by the user.
Load initrd & kernel
u-boot loads initrd and kernel from SD card into SDRAM.
Jump to kernel
u-boot transitions to the kernel on SDRAM.
The Linux kernel mounts rootfs and starts the rootfs program.