File tree Expand file tree Collapse file tree 2 files changed +36
-1
lines changed Expand file tree Collapse file tree 2 files changed +36
-1
lines changed Original file line number Diff line number Diff line change 11@ echo off
22
3- echo %0 : Generate new secure keys for stm32-secure-patching-bootloader
3+ echo %0 : Generate new secure keys for stm32-secure-patching-bootloader and Cortex-M0 (V6M) architecture devices
44
55set _KEY_TOOL = ..\Tools\prepareimage.py
66set _OUTPUT_DIR = %1
@@ -18,10 +18,14 @@ if NOT EXIST %_KEY_TOOL% (
1818
1919set _CIPHER_KEY = Cipher_Key_AES_CBC.bin
2020set _SIGNING_KEY = Signing_PrivKey_ECC.txt
21+ set _MACHINE_FILE = machine.txt
2122
2223echo Making %_OUTPUT_DIR% /%_CIPHER_KEY%
2324python %_KEY_TOOL% keygen -k %_OUTPUT_DIR% \%_CIPHER_KEY% -t aes-cbc
2425
2526echo Making %_OUTPUT_DIR% /%_SIGNING_KEY%
2627python %_KEY_TOOL% keygen -k %_OUTPUT_DIR% \%_SIGNING_KEY% -t ecdsa-p256
2728
29+ echo Making %_OUTPUT_DIR% /%_MACHINE_FILE%
30+ echo V6M > %_OUTPUT_DIR% /%_MACHINE_FILE%
31+
Original file line number Diff line number Diff line change 1+ @ echo off
2+
3+ echo %0 : Generate new secure keys for stm32-secure-patching-bootloader and Cortex-M3/M4/M7 (V7M and later) architecture devices
4+
5+ set _KEY_TOOL = ..\Tools\prepareimage.py
6+ set _OUTPUT_DIR = %1
7+
8+ if [%_OUTPUT_DIR% ]== [] (
9+ echo Please specify destination path to application Keys directory
10+ goto :eof
11+ )
12+
13+ if NOT EXIST %_KEY_TOOL% (
14+ echo Key generation tool is not found %_KEY_TOOL%
15+ goto :eof
16+ )
17+
18+
19+ set _CIPHER_KEY = Cipher_Key_AES_CBC.bin
20+ set _SIGNING_KEY = Signing_PrivKey_ECC.txt
21+ set _MACHINE_FILE = machine.txt
22+
23+ echo Making %_OUTPUT_DIR% /%_CIPHER_KEY%
24+ python %_KEY_TOOL% keygen -k %_OUTPUT_DIR% \%_CIPHER_KEY% -t aes-cbc
25+
26+ echo Making %_OUTPUT_DIR% /%_SIGNING_KEY%
27+ python %_KEY_TOOL% keygen -k %_OUTPUT_DIR% \%_SIGNING_KEY% -t ecdsa-p256
28+
29+ echo Making %_OUTPUT_DIR% /%_MACHINE_FILE%
30+ echo V7M > %_OUTPUT_DIR% /%_MACHINE_FILE%
31+
You can’t perform that action at this time.
0 commit comments