wolfBoot/tools/keytools
David Garske 601e46e480 Improved encryption constants between the bootloader and the signing tool. Allows the sign tool to properly use the correct block size for each encryption algorithm (64 for ChaCha, 16 for AES). 2025-12-31 11:25:09 -08:00
..
otp Update Copyright year to 2025 2025-10-15 11:33:53 -07:00
Makefile Refactor Makefiles to allow overriding library dependency paths 2025-10-02 15:16:27 +02:00
README.md Minor docs update, code review changes, script modifications. 2025-11-24 13:04:06 -08:00
keygen.c Introduce keygen --no-overwrite to avoid prompt 2025-11-13 17:59:22 +01:00
keygen.py Update Copyright year to 2025 2025-10-15 11:33:53 -07:00
sign.c Improved encryption constants between the bootloader and the signing tool. Allows the sign tool to properly use the correct block size for each encryption algorithm (64 for ChaCha, 16 for AES). 2025-12-31 11:25:09 -08:00
sign.py Update Copyright year to 2025 2025-10-15 11:33:53 -07:00
user_settings.h Update Copyright year to 2025 2025-10-15 11:33:53 -07:00
wolfBootKeyTools.sln
wolfBootKeygenTool.vcxproj
wolfBootSignTool.vcxproj Update project file line endings for Windows CRLF 2025-10-28 11:37:49 -07:00

README.md

Key Tools for signing and key generation

Sign

See code file ./tools/keytools/sign.c and documentation in docs/Signing.md.

KeyGen and KeyStore

See code file ./tools/keytools/keygen.c and documentation docs/keystore.md.

Flash OTP Keystore Generation, Primer, Startup

See documentation docs/flash-OTP.md.

Keystore Generation

Pack public keys into a single binary (otp.bin) formatted the way wolfBoot expects for provisioning the devices OTP/NVM keystore. No signing, no encryption—just a correctly laid-out image with a header plus fixed-size "slots" for each key.

See code file ./tools/keytools/otp/otp-keystore-gen.c

Flash OTP Primer

See code file ./tools/keytools/otp/otp-keystore-primer.c

Flash OTP Startup

See code file ./tools/keytools/otp/startup.c

Quick Start (Linux)

make wolfboot_signing_private_key.der SIGN=ED25519

# or

./tools/keytools/keygen --ed25519 -g wolfboot_signing_private_key.der

Note the above example is a basic case where a single key is generated. The tool supports multiple keys both with [-g privkey] and [-i pubkey] parameters.

See the local docs docs/keystore.md and the wolfBoot Keystore section of the manual for additional details.

Debugging and Development

DEBUG_SIGNTOOL

Enables additional diagnostic messages that may be useful during development and initial bring-up.

WOLFBOOT_SHOW_INCLUDE

Enables compile-time verbosity to indicate which user_settings.h file is being used.