wolfSSL / wolfBoot

wolfBoot is a portable, OS-agnostic, secure bootloader for microcontrollers, supporting firmware authentication and firmware update mechanisms.
https://www.wolfssl.com
GNU General Public License v3.0
331 stars 95 forks source link

Added support for custom TLVs in manifest header #412

Closed danielinux closed 4 months ago

danielinux commented 4 months ago

Added support in sign.c for custom TLVs in the manifest header. Numeric values are supported (valid len: 1, 2, 4 or 8). [edit: custom length buffers are also supported via --custom-tlv-buffer]

The numbers are stored in little-endian format (according to the current format of the other fields). The TLVs are part of the signed image, so their value is secured against modifications.

The custom fields stored in the TLV can be retrieved at runtime in wolfboot by using wolfBoot_find_header(). Documentation is updated accordingly.