storage: flash_map: Add SHA-256 integrity method
Add SHA-256 flash integrity method. It reads flash data from a device giving an offset creating a SHA-256 hash to be compared with a reference. On sucess match, zero is returned, otherwise a negative errno value. Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
This commit is contained in:
parent
9904022e77
commit
eb0f571790
7 changed files with 166 additions and 1 deletions
|
@ -28,4 +28,12 @@ config FLASH_MAP_CUSTOM
|
|||
User must provide such a description in place of default on
|
||||
if had enabled this option.
|
||||
|
||||
config FLASH_AREA_CHECK_INTEGRITY
|
||||
bool "Enable flash check functions"
|
||||
select TINYCRYPT
|
||||
select TINYCRYPT_SHA256
|
||||
help
|
||||
If enabled, there will be available the backend to check flash
|
||||
integrity using SHA-256 verification algorithm.
|
||||
|
||||
endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue