u-boot/test/py/tests/vboot
Alexandru Gagniuc 01e1e2a966 test/py: Check hashes produced by mkimage against known values
Target code and mkimage share the same hashing infrastructure. If one
is wrong, it's very likely that both are wrong in the same way. Thus
testing won't catch hash regressions. This already happened in
commit 92055e138f ("image: Drop if/elseif hash selection in
calculate_hash()"). None of the tests caught that CRC32 was broken.

Instead of testing hash_calculate() against itself, create a FIT with
containing a kernel with pre-calculated hashes. Then check the hashes
produced against the known good hashes.

Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2021-10-05 08:50:15 -04:00
..
hash-images.its test/py: Check hashes produced by mkimage against known values 2021-10-05 08:50:15 -04:00
sandbox-kernel.dts test: Convert the vboot test to test/py 2016-07-14 18:22:40 -04:00
sandbox-u-boot.dts test: Convert the vboot test to test/py 2016-07-14 18:22:40 -04:00
sign-configs-sha1-pss.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-configs-sha1.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-configs-sha256-pss-prod.its pytest: vboot: add a test for required key 2019-10-15 08:40:02 -06:00
sign-configs-sha256-pss.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-configs-sha256.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-images-sha1-pss.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-images-sha1.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-images-sha256-pss.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00
sign-images-sha256.its test: vboot: clean its file 2018-12-03 10:44:10 -05:00