Changes between Version 13 and Version 14 of venice/secure_boot
- Timestamp:
- 03/20/2024 12:44:42 AM (8 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
venice/secure_boot
v13 v14 26 26 27 27 == i.MX secure boot 28 Boards using U-Boot for boot firmware support using HABv4 authentication for both images.28 Boards using U-Boot for boot firmware support using HABv4 authentication for both the SPL and U-Boot stages. 29 29 30 30 The HAB library is a sub-component of the boot ROM on i.MX processors. It is responsible for verifying the digital signatures included as part of the product software and ensures that, when the processor is configured as a secure device, no unauthenticated code is allowed to run. … … 35 35 - Build boot firmware that contains HABv4 support 36 36 - CONFIG_IMX_HAB=y ('hab_auto_img', 'hab_status' and 'hab_version' cmds) 37 - CONFIG_CMD_FSL_CAAM_KB=y ('caam genblob' and 'caam decap' cmds) 38 - CONFIG_CMD_DEKBLOB=y (optional) ('dek_blob' cmd) 39 - CONFIG_SPL_LOAD_FIT_ADDRESS=0x48000000 37 - CONFIG_SPL_LOAD_FIT_ADDRESS=0x44000000 40 38 - Create a PKI tree and SRK table via the NXP Code Signing Tool 41 39 - Construct boot firmware with a proper Command Sequence File (CSF) (CSF blobs are created with the NXP Code Signing Tool) … … 45 43 - Close the device to force trusted boot 46 44 47 Detailed Procedure (for Venice) on x86 host machine: 45 Detailed Procedure (for Venice) on x86 development host machine with an existing venice bsp build directory on it (VENICE_BSP env var): 46 - this configuration is for using HABv4 for image authentication only on the Gateworks 2023.04 U-Boot branch. If you instead want to use DEK blob encap/decap support you need to to also add a Trusted Execution Environment (TEE) (see below) 48 47 1. Creation of Code Signing Key: '''This is an example - read the CST documentation and tailor to your needs''' 49 48 a. Retrieve the NXP Code Signing Tool (CST): https://www.nxp.com/webapp/Download?colCode=IMX_CST_TOOL_NEW (Account required on NXP site) … … 110 109 # configure for venice board 111 110 make imx8mm_venice_defconfig 112 make menuconfig # select CONFIG_IMX_HAB=y and CONFIG_SPL_LOAD_FIT_ADDRESS=0x4 8000000111 make menuconfig # select CONFIG_IMX_HAB=y and CONFIG_SPL_LOAD_FIT_ADDRESS=0x44000000 113 112 make flash.bin 114 113 }}} … … 149 148 hab fuse not enabled 150 149 151 Authenticate image from DDR location 0x4 8000000...150 Authenticate image from DDR location 0x44000000... 152 151 DTB : imx8mm-venice-gw72xx-0x 153 152 NOTICE: BL31: v2.4(release):f884ad7b0ba2 … … 190 189 - https://elixir.bootlin.com/u-boot/latest/source/doc/imx/habv4/guides/mx8m_spl_secure_boot.txt 191 190 191 [=#tee] 192 192 == Trusted Execution Environment (TEE) 193 193 The Trusted Execution Environment (TEE) is a set of specifications published by the [http://www.globalplatform.org GlobalPlatform association]. The purpose of the TEE is to provide a safe environment within the application processor for developing and executing secure applications. We call an application processor a system running a Rich OS like Android or Linux. A Rich environment represents a huge amount of code. It is open to third-party applications and it is an open ecosystem: it makes a Rich OS hard to audit. It is prone to bugs/vulnerability, which may compromise the security and integrity of the entire system. The TEE offers another level of protection against attacks from the rich OS. The TEE is only open to trusted partners, which makes it easier to audit. It executes only trusted and authorized software. All sensitive data are protected from the rest of the application processor and from the outside world. … … 243 243 - CONFIG_IMX_HAB=y 244 244 - CONFIG_CMD_DEKBLOB=y 245 - CONFIG_SPL_LOAD_FIT_ADDRESS=0x4 8000000245 - CONFIG_SPL_LOAD_FIT_ADDRESS=0x44000000 246 246 - CONFIG_OPTEE=y 247 247 - CONFIG_OPTEE_LOAD_ADDRESS= the (link/load) address for TEE that should match BL32_BASE for ATF and CFG_TZDRAM_START for OPTEE … … 324 324 make imx8mm_venice_defconfig # choose imx8mm/imx8mn/imx8mp depending on board SOC 325 325 # enable IMX_HAB/OPTEE 326 make menuconfig # search for (with /) and set CONFIG_IMX_HAB=y CONFIG_CMD_DEKBLOB=y CONFIG_SPL_LOAD_FIT_ADDRESS=0x4 8000000 CONFIG_OPTEE=y and CONFIG_OPTEE_LOAD_ADDRESS= set to the value of CFG_TZDRAM_START326 make menuconfig # search for (with /) and set CONFIG_IMX_HAB=y CONFIG_CMD_DEKBLOB=y CONFIG_SPL_LOAD_FIT_ADDRESS=0x44000000 CONFIG_OPTEE=y and CONFIG_OPTEE_LOAD_ADDRESS= set to the value of CFG_TZDRAM_START 327 327 make -j8 flash.bin 328 328 }}}