MCUXpresso SDK API Reference Manual  Rev 2.16.000
NXP Semiconductors
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
NBOOT_HAL Driver

Overview

Files

file  fsl_nboot_hal.h
 

Data Structures

struct  _nboot_sb3_header
 NBOOT SB3.1 header type. More...
 
struct  _nboot_certificate_header_block
 NBOOT type for the header of the certificate block. More...
 
struct  _nboot_ctrk_hash_table
 NBOOT type for the hash table. More...
 
struct  nboot_ecdsa_public_key_t
 NBOOT type for an ECC point. More...
 
struct  _nboot_root_certificate_block
 NBOOT type for the root certificate block. More...
 
struct  nboot_ecdsa_signature_t
 NBOOT type for an ECC signature. More...
 
struct  nboot_isk_block_t
 NBOOT type for the isk block. More...
 
struct  _nboot_certificate_block
 NBOOT type for the certificate block. More...
 

Macros

#define NBOOT_UUID_SIZE_IN_WORD   (4)
 The size of the UUID. More...
 
#define NBOOT_PUF_AC_SIZE_IN_BYTE   (996)
 The size of the PUF activation code. More...
 
#define NBOOT_PUF_KC_SIZE_IN_BYTE   (84)
 The size of the PUF key code. More...
 
#define NBOOT_KEY_STORE_SIZE_IN_BYTE   (NBOOT_PUF_AC_SIZE_IN_BYTE + 8)
 The size of the key store. More...
 
#define NBOOT_ROOT_ROTKH_SIZE_IN_WORD   (12)
 The size of the root of trust key table hash. More...
 
#define NBOOT_KEY_BLOB_SIZE_IN_BYTE_256   (32)
 The size of the blob with Key Blob. More...
 
#define NBOOT_DBG_AUTH_DBG_STATE_MASK   (0x0000FFFFu)
 The mask of the value of the debug state . More...
 
#define NBOOT_DBG_AUTH_DBG_STATE_SHIFT   (16)
 The shift inverted value of the debug state. More...
 
#define NBOOT_DBG_AUTH_DBG_STATE_ALL_DISABLED   (0xFFFF0000u)
 The value with all debug feature disabled. More...
 
#define NBOOT_DICE_CSR_SIZE_IN_WORD   (36)
 The size of the DICE certificate. More...
 
#define NBOOT_DICE_CSR_ADDRESS   (0x30000000u)
 The physical address to put the DICE certificate. More...
 
#define NBOOT_IPED_IV_OFFSET   (3U)
 The offset for the PRCINE/IPED erase region return by nboot mem checker. More...
 

Typedefs

typedef uint32_t nboot_timestamp_t [2]
 NBOOT type for a timestamp. More...
 
typedef struct _nboot_sb3_header nboot_sb3_header_t
 NBOOT SB3.1 header type. More...
 
typedef struct
_nboot_certificate_header_block 
nboot_certificate_header_block_t
 NBOOT type for the header of the certificate block. More...
 
typedef struct
_nboot_ctrk_hash_table 
nboot_ctrk_hash_table_t
 NBOOT type for the hash table. More...
 
typedef uint8_t nboot_ecc_coordinate_t [NBOOT_EC_COORDINATE_MAX_SIZE]
 NBOOT type for an ECC coordinate. More...
 
typedef struct
_nboot_root_certificate_block 
nboot_root_certificate_block_t
 NBOOT type for the root certificate block. More...
 
typedef struct
_nboot_certificate_block 
nboot_certificate_block_t
 NBOOT type for the certificate block. More...
 
typedef enum _nboot_hash_algo_t nboot_hash_algo_t
 Algorithm used for nboot HASH operation.
 

Enumerations

enum  _nboot_hash_algo_t {
  kHASH_Sha1 = 1,
  kHASH_Sha256 = 2,
  kHASH_Sha512 = 3,
  kHASH_Aes = 4,
  kHASH_AesIcb = 5
}
 Algorithm used for nboot HASH operation. More...
 

Data Structure Documentation

struct _nboot_sb3_header

This type defines the header used in the SB3.1 manifest

Data Fields

uint32_t magic
 offset 0x00: Fixed 4-byte string of 'sbv3' without the trailing NULL
 
uint32_t formatVersion
 offset 0x04: (major = 3, minor = 1); The format version determines the manifest (block0) size. More...
 
uint32_t flags
 offset 0x08: not defined yet, keep zero for future compatibility
 
uint32_t blockCount
 offset 0x0C: Number of blocks not including the manifest (block0). More...
 
uint32_t blockSize
 offset 0x10: Size in bytes of data block (repeated blockCount times for SB3 data stream). More...
 
nboot_timestamp_t timeStamp
 offset 0x14: 64-bit value used as key derivation data. More...
 
uint32_t firmwareVersion
 offset 0x1c: Version number of the included firmware
 
uint32_t imageTotalLength
 offset 0x20: Total manifest length in bytes, including signatures etc. More...
 
uint32_t imageType
 offset 0x24: image type and flags
 
uint32_t certificateBlockOffset
 offset 0x28: Offset from start of header block to the certificate block. More...
 
uint8_t description [16]
 offset 0x32: This field provides description of the file. More...
 

Field Documentation

uint32_t _nboot_sb3_header::formatVersion
uint32_t _nboot_sb3_header::blockCount
uint32_t _nboot_sb3_header::blockSize
nboot_timestamp_t _nboot_sb3_header::timeStamp
uint32_t _nboot_sb3_header::imageTotalLength
uint32_t _nboot_sb3_header::certificateBlockOffset
uint8_t _nboot_sb3_header::description[16]

It is an arbitrary string injected by the signing tool, which helps to identify the file.

struct _nboot_certificate_header_block

This type defines the NBOOT header of the certificate block, it is part of the nboot_certificate_block_t

Data Fields

uint32_t magic
 magic number. More...
 
uint32_t formatMajorMinorVersion
 format major minor version
 
uint32_t certBlockSize
 Size of the full certificate block.
 

Field Documentation

uint32_t _nboot_certificate_header_block::magic
struct _nboot_ctrk_hash_table

This type defines the NBOOT hash table

struct nboot_ecdsa_public_key_t

This type defines the NBOOT ECC point type

Data Fields

nboot_ecc_coordinate_t x
 x portion of the ECDSA public key, up to 384-bits. More...
 
nboot_ecc_coordinate_t y
 y portion of the ECDSA public key, up to 384-bits. More...
 

Field Documentation

nboot_ecc_coordinate_t nboot_ecdsa_public_key_t::x

big endian.

nboot_ecc_coordinate_t nboot_ecdsa_public_key_t::y

big endian.

struct _nboot_root_certificate_block

This type defines the NBOOT root certificate block, it is part of the nboot_certificate_block_t

Data Fields

uint32_t flags
 root certificate flags
 
nboot_ctrk_hash_table_t ctrkHashTable
 hash table
 
nboot_ecdsa_public_key_t rootPublicKey
 root public key
 
struct nboot_ecdsa_signature_t

This type defines the NBOOT ECC signature type

Data Fields

nboot_ecc_coordinate_t r
 r portion of the ECDSA signature, up to 384-bits. More...
 
nboot_ecc_coordinate_t s
 s portion of the ECDSA signature, up to 384-bits. More...
 

Field Documentation

nboot_ecc_coordinate_t nboot_ecdsa_signature_t::r

big endian.

nboot_ecc_coordinate_t nboot_ecdsa_signature_t::s

big endian.

struct nboot_isk_block_t

This type defines the constant length part of an NBOOT isk block

Data Fields

uint32_t signatureOffset
 Offset of signature in ISK block. More...
 
uint32_t constraints
 Version number of signing certificate. More...
 
uint32_t iskFlags
 Reserved for definiton of ISK certificate flags. More...
 
nboot_ecdsa_public_key_t iskPubKey
 Public key of signing certificate. More...
 
nboot_ecdsa_public_key_t userData
 Space for at lest one addition public key.
 
nboot_ecdsa_signature_t iskSign
 ISK signature.
 

Field Documentation

uint32_t nboot_isk_block_t::signatureOffset
uint32_t nboot_isk_block_t::constraints
uint32_t nboot_isk_block_t::iskFlags
nboot_ecdsa_public_key_t nboot_isk_block_t::iskPubKey

Variable length; only used to determine start address

struct _nboot_certificate_block

This type defines the constant length part of an NBOOT certificate block

Data Fields

nboot_isk_block_t iskBlock
 Details of selected root certificate (root certificate which will be used for ISK signing/SB3 header signing)
 

Macro Definition Documentation

#define NBOOT_UUID_SIZE_IN_WORD   (4)
#define NBOOT_PUF_AC_SIZE_IN_BYTE   (996)
#define NBOOT_PUF_KC_SIZE_IN_BYTE   (84)
#define NBOOT_KEY_STORE_SIZE_IN_BYTE   (NBOOT_PUF_AC_SIZE_IN_BYTE + 8)
#define NBOOT_ROOT_ROTKH_SIZE_IN_WORD   (12)
#define NBOOT_KEY_BLOB_SIZE_IN_BYTE_256   (32)
#define NBOOT_DBG_AUTH_DBG_STATE_MASK   (0x0000FFFFu)
#define NBOOT_DBG_AUTH_DBG_STATE_SHIFT   (16)
#define NBOOT_DBG_AUTH_DBG_STATE_ALL_DISABLED   (0xFFFF0000u)
#define NBOOT_DICE_CSR_SIZE_IN_WORD   (36)
#define NBOOT_DICE_CSR_ADDRESS   (0x30000000u)
#define NBOOT_IPED_IV_OFFSET   (3U)

Typedef Documentation

typedef uint32_t nboot_timestamp_t[2]

This type defines the NBOOT timestamp

This type defines the header used in the SB3.1 manifest

This type defines the NBOOT header of the certificate block, it is part of the nboot_certificate_block_t

This type defines the NBOOT hash table

typedef uint8_t nboot_ecc_coordinate_t[NBOOT_EC_COORDINATE_MAX_SIZE]

This type defines the NBOOT ECC coordinate typeECC point coordinate, up to 384-bits. big endian.

This type defines the NBOOT root certificate block, it is part of the nboot_certificate_block_t

This type defines the constant length part of an NBOOT certificate block

Enumeration Type Documentation

Enumerator
kHASH_Sha1 

SHA_1.

kHASH_Sha256 

SHA_256.

kHASH_Sha512 

SHA_512.

kHASH_Aes 

AES.

kHASH_AesIcb 

AES_ICB.