From bfcb6e16ab669814478b1de63e48d4ff6b408711 Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Thu, 9 Apr 2020 18:33:34 +0200 Subject: [PATCH] Create a large enough seedfile The seedfile needs to have the size of the entropy accumulator, which is 64 bytes (512 bits) since the entropy accumulator uses SHA-512 and the seed size needs to be the same as the hash output (or larger). We used to enable MBEDTLS_ENTROPY_FORCE_SHA256 in the full config, so the entropy accumulator was 256 bits (32 bytes), and therefore a 32-byte seedfile worked. But we no longer turn on this option in the full config, so the 32-byte seedfile no longer works. Signed-off-by: Gilles Peskine --- tests/scripts/basic-build-test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/scripts/basic-build-test.sh b/tests/scripts/basic-build-test.sh index e248c2267..bbfcf25c8 100755 --- a/tests/scripts/basic-build-test.sh +++ b/tests/scripts/basic-build-test.sh @@ -76,7 +76,7 @@ make -j TEST_OUTPUT=out_${PPID} cd tests if [ ! -f "seedfile" ]; then - dd if=/dev/urandom of="seedfile" bs=32 count=1 + dd if=/dev/urandom of="seedfile" bs=64 count=1 fi # Step 2a - Unit Tests (keep going even if some tests fail)