[PATCH] bootm: bootm_open_initrd_uimage(): propagate error if initrd verification fails
Sascha Hauer
s.hauer at pengutronix.de
Tue Sep 19 23:21:22 PDT 2017
On Tue, Sep 19, 2017 at 01:49:07PM +0200, Marc Kleine-Budde wrote:
> If the verification of an initrd inside of an uImage fails an error message is
> printed but the error is not propagated. Although this is not security
> relevant, as the verification is currently only a CRC32 check, the error should
> be returned. This patch fixes the problem.
>
> Signed-off-by: Marc Kleine-Budde <mkl at pengutronix.de>
Applied, thanks
Sascha
> ---
> common/bootm.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/common/bootm.c b/common/bootm.c
> index 81625d9157cc..eebaa799f548 100644
> --- a/common/bootm.c
> +++ b/common/bootm.c
> @@ -173,6 +173,7 @@ static int bootm_open_initrd_uimage(struct image_data *data)
> if (ret) {
> printf("Checking data crc failed with %s\n",
> strerror(-ret));
> + return ret;
> }
> }
> uimage_print_contents(data->initrd);
> --
> 2.11.0
>
>
> _______________________________________________
> barebox mailing list
> barebox at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
>
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list