userkeys - 2024.1 简体中文

Bootgen 用户指南 (UG1283)

Document ID
UG1283
Release Date
2024-05-30
Version
2024.1 简体中文

语法

userkeys = <filename>                              

文件格式

user_key0 <userkey0 value>                                     
user_key1 <userkey1 value>                                     
user_key2 <userkey2 value>                                     
user_key3 <userkey3 value>                                      
user_key4 <userkey4 value>                                      
user_key5 <userkey5 value>                                    
user_key6 <userkey6 value>                                     
user_key7 <userkey7 value>

描述

指向用户密钥文件的路径。密钥文件包含用于加密分区的用户密钥。用户密钥的大小可以为 128 或 256 位。128 位密钥只能用于运行时加载的分区。

示例

在以下示例中,FPD 分区将密钥源用作 user_key2,因此该分区的 .nky 文件必须使用 userkeys 文件中的 user_key2 作为 key0。然后,Bootgen 使用 .nky 文件中的此 key0 进行加密。解密期间,PLM 将使用由 pmc_data 编程的 user_key2

new_bif:
{
 userkeys = userkeyfile.txt
 id_code = 0x14ca8093
 extended_id_code = 0x01
 id = 0x2
 image
 {
  name = pmc_subsys
  id = 0x1c000001
  partition
  {
   id = 0x01
   type = bootloader
   encryption = aes
   keysrc=bbram_red_key
   aeskeyfile = inputs/keys/enc/bbram_red_key.nky
   dpacm_enable
   file = gen_files/plm.elf
  }
  partition
  {
   id = 0x09
   type = pmcdata, load = 0xf2000000
   file = gen_files/pmc_data.cdo
  }
 }
 image
 {
  name = lpd
  id = 0x4210002
  partition
  {
   id = 0x0C
   type = cdo
   file = gen_files/lpd_data.cdo
  }
  partition
  {
   id = 0x0B
   core = psm
   file = static_files/psm_fw.elf
  }
 }
 image
 {
  name = pl_cfi
  id = 0x18700000
  partition
  {
   id = 0x03
   type = cdo
   file = design_1_wrapper.rcdo
  }
  partition
  {
   id = 0x05
   type = cdo
   file = design_1_wrapper.rnpi
  }
 }
 image
 {
  name = fpd
  id = 0x420c003
  partition
  {
   id = 0x08
   type = cdo
   file = gen_files/fpd_data.cdo
   encryption = aes
   keysrc=user_key2
   aeskeyfile = userkey2.nky
  }
 }
 image
 {
  name = ss_apu
  id = 0x1c000000
  partition
  { 
   id = 0x61
   core = a72-0
   file = ./wrk_a72_r5/perip_a72/Debug/perip_a72.elf 
  }
 }
}