From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Rini Date: Mon, 15 Feb 2021 22:36:14 -0500 Subject: [PATCH 5/8] image: Adjust the workings of fit_check_format() In-Reply-To: <20210216000812.2091481-6-sjg@chromium.org> References: <20210216000812.2091481-1-sjg@chromium.org> <20210216000812.2091481-6-sjg@chromium.org> Message-ID: <20210216033614.GR10169@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Mon, Feb 15, 2021 at 05:08:09PM -0700, Simon Glass wrote: > At present this function does not accept a size for the FIT. This means > that it must be read from the FIT itself, introducing potential security > risk. Update the function to include a size parameter, which can be > invalid, in which case fit_check_format() calculates it. > > For now no callers pass the size, but this can be updated later. > > Also adjust the return value to an error code so that all the different > types of problems can be distinguished by the user. > > Signed-off-by: Simon Glass > Reported-by: Bruce Monroe > Reported-by: Arie Haenel > Reported-by: Julien Lenoir Applied to u-boot/master, thanks! -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: