OTA image has invalid magic byte - (Encrypted binary update - OTA )
Posted: Tue Nov 22, 2022 6:36 am
Hi,
I'm working on Flash encryption on ESP32 (using ESP IDF framework V4.4 in Visual Studio Code IDE) with pre-generated key on host machine. I was able to burn the key on esp32 and I merged the encrypted binaries (used espsecure.py to encrypt the binary with pre-generated key) (app.bin, bootloader.bin and custiomized_parition.bin) into one binary (final.bin)and I able to flash it and it was running without any error. When I try to update the image via OTA (used encrypted app.bin ), inside esp_ota_write(), it was thrown the error message "esp_ota_ops: OTA image has invalid magic byte (expected 0xE9, saw 0x27)".Could anyone pls help me on this, what i'm missing?
I'm working on Flash encryption on ESP32 (using ESP IDF framework V4.4 in Visual Studio Code IDE) with pre-generated key on host machine. I was able to burn the key on esp32 and I merged the encrypted binaries (used espsecure.py to encrypt the binary with pre-generated key) (app.bin, bootloader.bin and custiomized_parition.bin) into one binary (final.bin)and I able to flash it and it was running without any error. When I try to update the image via OTA (used encrypted app.bin ), inside esp_ota_write(), it was thrown the error message "esp_ota_ops: OTA image has invalid magic byte (expected 0xE9, saw 0x27)".Could anyone pls help me on this, what i'm missing?