preencrypted

This commit is contained in:
ok-home
2023-10-03 14:59:03 +07:00
committed by GitHub
parent 8466454a65
commit 4c5878ee10
3 changed files with 238 additions and 2 deletions

View File

@@ -1,4 +1,26 @@
idf_component_register(
if(CONFIG_OTA_PRE_ENCRYPTED_MODE)
idf_component_register(
SRCS
source/ota_ws_update_esp_preencrypted.c
source/ota_ws_update_http.c
INCLUDE_DIRS
include
PRIV_INCLUDE_DIRS
private_include
REQUIRES
esp_http_server
app_update
esp_encrypted_img
#esp_wifi
EMBED_FILES
source/ota_ws_update.html
rsa_key/private.pem
)
#openssl genrsa -out rsa_key/private.pem 3072
create_esp_enc_img(${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}.bin
${project_dir}/rsa_key/private.pem ${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}_secure.bin app)
else()
idf_component_register(
SRCS
source/ota_ws_update_esp.c
source/ota_ws_update_http.c
@@ -12,4 +34,5 @@ idf_component_register(
#esp_wifi
EMBED_FILES
source/ota_ws_update.html
)
)
endif()