Added bootloader_common_get_sha256_of_partition() and esp_partition_get_sha256() - get or calculate SHA-256 digest for app and data partitions. Added bootloader_sha256_hex_to_str() - helps to print SHA-256 digest Added esp_partition_check_identity() - compares two partitions by SHA-256 digest Refactoring a function esp_image_load() in bootloader space to esp_image_verify() and bootloader_load_image(). Old name function esp_image_load is deprecated and will remove in V4.0 version. spi_flash/sim: Fix error test_host. Add stub for bootloader_common_get_sha256_of_partition in sim/stubs
20 lines
806 B
C
20 lines
806 B
C
// Copyright 2018 Espressif Systems (Shanghai) PTE LTD
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
#pragma once
|
|
#include <stdint.h>
|
|
#include <stdio.h>
|
|
#include "esp_err.h"
|
|
|
|
esp_err_t bootloader_common_get_sha256_of_partition(uint32_t address, uint32_t size, int type, uint8_t *out_sha_256);
|