mirror of
https://xff.cz/git/u-boot/
synced 2025-09-04 10:12:14 +02:00
mkimage: fit: Fix signing of configs with external data
Just like we exclude data-size, data-position, and data-offset from fit_config_check_sig, we must exclude them while signing as well. While we're at it, use the FIT_DATA_* defines for fit_config_check_sig as welll. Fixes:8edecd3110
("fit: Fix verification of images with external data") Fixes:c522949a29
("rsa: sig: fix config signature check for fit with padding") Signed-off-by: Sean Anderson <sean.anderson@seco.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -260,10 +260,10 @@ static int fit_config_check_sig(const void *fit, int noffset, int conf_noffset,
|
|||||||
char **err_msgp)
|
char **err_msgp)
|
||||||
{
|
{
|
||||||
static char * const exc_prop[] = {
|
static char * const exc_prop[] = {
|
||||||
"data",
|
FIT_DATA_PROP,
|
||||||
"data-size",
|
FIT_DATA_SIZE_PROP,
|
||||||
"data-position",
|
FIT_DATA_POSITION_PROP,
|
||||||
"data-offset"
|
FIT_DATA_OFFSET_PROP,
|
||||||
};
|
};
|
||||||
|
|
||||||
const char *prop, *end, *name;
|
const char *prop, *end, *name;
|
||||||
|
@@ -915,7 +915,12 @@ static int fit_config_get_regions(const void *fit, int conf_noffset,
|
|||||||
int *region_countp, char **region_propp,
|
int *region_countp, char **region_propp,
|
||||||
int *region_proplen)
|
int *region_proplen)
|
||||||
{
|
{
|
||||||
char * const exc_prop[] = {"data"};
|
char * const exc_prop[] = {
|
||||||
|
FIT_DATA_PROP,
|
||||||
|
FIT_DATA_SIZE_PROP,
|
||||||
|
FIT_DATA_POSITION_PROP,
|
||||||
|
FIT_DATA_OFFSET_PROP,
|
||||||
|
};
|
||||||
struct strlist node_inc;
|
struct strlist node_inc;
|
||||||
struct image_region *region;
|
struct image_region *region;
|
||||||
struct fdt_region fdt_regions[100];
|
struct fdt_region fdt_regions[100];
|
||||||
|
Reference in New Issue
Block a user