Skip to content

Commit 9288a34

Browse files
committed
[nrf noup] sysbuild: Support for ED25519 with SHA512 and PureEdDSA
The commit adds imgtool parameters that allow to sign image with SHA512, for ED25519, or use PureEdDSA variant, where signature is calculated over entire image rather than SHA of that image. Signed-off-by: Dominik Ermel <[email protected]>
1 parent 53b26fb commit 9288a34

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

share/sysbuild/image_configurations/MAIN_image_default.cmake

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,16 @@ if(SB_CONFIG_BOOTLOADER_MCUBOOT)
3737
elseif(SB_CONFIG_MCUBOOT_MODE_FIRMWARE_UPDATER)
3838
set_config_bool(${ZCMAKE_APPLICATION} CONFIG_MCUBOOT_BOOTLOADER_MODE_FIRMWARE_UPDATER y)
3939
endif()
40+
41+
set(imgtool_extra_args "${CONFIG_MCUBOOT_EXTRA_IMGTOOL_ARGS}")
42+
if(SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519)
43+
if(SB_CONFIG_BOOT_SIGNATURE_TYPE_PURE)
44+
string(APPEND imgtool_extra_args " --pure")
45+
else()
46+
string(APPEND imgtool_extra_args " --sha 512")
47+
endif()
48+
endif()
49+
50+
set_config_string(${ZCMAKE_APPLICATION} CONFIG_MCUBOOT_EXTRA_IMGTOOL_ARGS "${imgtool_extra_args}")
51+
4052
endif()

0 commit comments

Comments
 (0)