lib/crypto: tests: Add KUnit tests for SHA-384 and SHA-512
authorEric Biggers <ebiggers@kernel.org>
Wed, 9 Jul 2025 20:01:11 +0000 (13:01 -0700)
committerEric Biggers <ebiggers@kernel.org>
Mon, 14 Jul 2025 18:29:36 +0000 (11:29 -0700)
commit571eaeddb67df84c4fd59c5496866c049fb25efe
tree29d04956de925ac5301781e3ca4da95886ca14c7
parent4dcf6caddaa0471c134bf0c869086fd0b57a9cc4
lib/crypto: tests: Add KUnit tests for SHA-384 and SHA-512

Add KUnit test suites for the SHA-384 and SHA-512 library functions,
including the corresponding HMAC support.  The core test logic is in the
previously-added hash-test-template.h.  This commit just adds the actual
KUnit suites, and it adds the generated test vectors to the tree so that
gen-hash-testvecs.py won't have to be run at build time.

Acked-by: Ard Biesheuvel <ardb@kernel.org>
Link: https://lore.kernel.org/r/20250709200112.258500-4-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
lib/crypto/tests/Kconfig
lib/crypto/tests/Makefile
lib/crypto/tests/sha384-testvecs.h [new file with mode: 0644]
lib/crypto/tests/sha384_kunit.c [new file with mode: 0644]
lib/crypto/tests/sha512-testvecs.h [new file with mode: 0644]
lib/crypto/tests/sha512_kunit.c [new file with mode: 0644]