Esptool is a Python-based, open-source, platform-independent utility to communicate with the ROM bootloader in Espressif chips.
Integrate OpenSSL with DigiCert® Software Trust Manager’s PKCS11 library, then use OpenSSL, to sign the image using Espressif’s detached signature functionality. Use these instructions set up, sign and verify signatures using the Esptool utility script bundled with the Espressif build system.
DigiCert ONE client authentication certificate
Software Trust Manager keypair
OpenSSL with DigiCert® Software Trust Manager PKCS11 library
Esptool (version 4.5 or higher)
To install Esptool, run the following command from command line:
pip install esptool[hsm]
Note
For additional context, refer to Installation and dependancies.
Follow these instructions to install OpenSSL and configure it with Software Trust Manager PKCS11 library.
To sign, use the command:
espsecure.py sign_data --version 2 --pub-key <public-key-from-keypair-used-to-sign> --signature <signature-output-file-from-openssl> --output <final-signed-image-output-name> <input-image>
Command example: