Changes between Version 6 and Version 7 of venice/secure_boot


Ignore:
Timestamp:
06/12/2023 04:45:49 PM (18 months ago)
Author:
Tim Harvey
Comment:

add wget for grabbing the helper script from attachment and boot consoles for various steps

Legend:

Unmodified
Added
Removed
Modified
  • venice/secure_boot

    v6 v7  
    175175export SRK_TABLE=$CST_DIR/crts/SRK_1_2_3_4_table.bin
    176176# sign it
     177$ wget http://trac.gateworks.com/raw-attachment/wiki/venice/secure_boot/sign_hab_imx8m.sh
     178$ chmod +x sign_hab_imx8m.sh
    177179$ ./sign_hab_imx8m.sh
    178180Install SRK
     
    199201}}}
    200202  * the script will create csf_spl.txt and csf_fit.txt which are templates used to create csf_spl.bin and csf_fit.bin which are then copied to the correct offsets in flash.bin to create signed_flash.bin
     203  * on a board without SRK Hash fuses programmed and flashed with this signed image the serial console will look this this:
     204{{{#!bash
     205U-Boot SPL 2021.07-00087-g54ac394a7c74 (Jun 09 2023 - 14:39:52 -0700)
     206GSCv3   : v61 0x1d6f RST:VIN Thermal protection:disabled
     207RTC     : 1970-01-01   0:00:31 UTC
     208Model   : GW7301-00-B1B
     209Serial  : 852420
     210MFGDate : 11-19-2021
     211PMIC    : MP5416
     212DRAM    : LPDDR4 1 GiB
     213WDT:   Started with servicing (60s timeout)
     214Trying to boot from MMC1
     215DTB     : imx8mm-venice-gw73xx-0x
     216hab fuse not enabled
     217
     218Authenticate image from DDR location 0x401fcdc0...
     219NOTICE:  BL31: v2.4(release):f884ad7b0ba2
     220NOTICE:  BL31: Built : 13:06:09, Oct 20 2021
     221
     222
     223U-Boot 2021.07-00087-g54ac394a7c74 (Jun 09 2023 - 14:39:52 -0700)
     224
     225CPU:   Freescale i.MX8MMQ rev1.0 1600 MHz (running at 1200 MHz)
     226CPU:   Industrial temperature grade (-40C to 105C) at 34C
     227Reset cause: POR
     228Model: Gateworks Venice GW73xx-0x i.MX8MM Development Kit
     229DRAM:  1 GiB
     230WDT:   Started with servicing (60s timeout)
     231MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
     232Loading Environment from MMC... OK
     233In:    serial
     234Out:   serial
     235Err:   serial
     236Net:   DP83867 eth0: ethernet@30be0000 [PRIME]
     237GSC     : boot watchdog disabled
     238Hit any key to stop autoboot:  0
     239u-boot=> 
     240}}}
     241  - Note the 'hab fuse not enabled' and the 'Authenticate image from DDR location' messages
    201242 4. Program SRK Hash fuses from Step 1 into IMX OTP (using U-Boot and the keys from fuse bin)
    202243{{{#!bash
     
    226267 7 Close the device (lock it down!) - this step is irreversible, make sure there are no HAB events from the prior step
    227268{{{#!bash
    228 u-boot=> fuse prog 1 3 0x2000000
     269u-boot=> fuse prog -y 1 3 0x2000000
    229270}}}
    230271  * This sets the SEC_CONFIG[1] fuse on the i.MX8M and once done the processor will not load an image that has not been signed using the correct PKI tree
     272  * on a board with SRK Hash fuses programmed, SEC_CONFIG[1] set and flashed with a signed image the serial console will look this this:
     273{{{#!bash
     274U-Boot SPL 2021.07-00087-g54ac394a7c74 (Jun 09 2023 - 14:39:52 -0700)
     275GSCv3   : v58 0xf098 RST:VIN Thermal protection:enabled at 96C
     276RTC     : 1970-01-03  16:34:29 UTC
     277Model   : GW7301-01-B1B
     278Serial  : 852455
     279MFGDate : 11-10-2020
     280PMIC    : MP5416
     281DRAM    : LPDDR4 4 GiB
     282WDT:   Started with servicing (60s timeout)
     283Trying to boot from MMC1
     284DTB     : imx8mm-venice-gw73xx-0x
     285
     286Authenticate image from DDR location 0x401fcdc0...
     287NOTICE:  BL31: v2.4(release):f884ad7b0ba2
     288NOTICE:  BL31: Built : 13:06:09, Oct 20 2021
     289
     290
     291U-Boot 2021.07-00087-g54ac394a7c74 (Jun 09 2023 - 14:39:52 -0700)
     292
     293CPU:   Freescale i.MX8MMQ rev1.0 1600 MHz (running at 1200 MHz)
     294CPU:   Industrial temperature grade (-40C to 105C) at 30C
     295Reset cause: POR
     296Model: Gateworks Venice GW73xx-0x i.MX8MM Development Kit
     297DRAM:  4 GiB
     298WDT:   Started with servicing (60s timeout)
     299MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
     300Loading Environment from MMC... OK
     301In:    serial
     302Out:   serial
     303Err:   serial
     304Net:   DP83867 eth0: ethernet@30be0000 [PRIME]
     305GSC     : boot watchdog disabled
     306Thermal protection:enabled at 96C
     307Hit any key to stop autoboot:  0
     308}}}
     309  - Note the 'Authenticate image from DDR location' message
    231310
    232311== HABv4 encrypted boot architecture