]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
fsverity: Switch from crypto_shash to SHA-2 library
authorEric Biggers <ebiggers@kernel.org>
Mon, 30 Jun 2025 17:22:24 +0000 (10:22 -0700)
committerEric Biggers <ebiggers@kernel.org>
Mon, 14 Jul 2025 18:29:32 +0000 (11:29 -0700)
commit998646b3c1129188f1fdffac3779feb9708b4b4a
treed7cce8b2f1073958caca922909e1951ed8b3ef3f
parentb309bf7c3e35e86e414921ff655a9578016a1788
fsverity: Switch from crypto_shash to SHA-2 library

fsverity supports two hash algorithms: SHA-256 and SHA-512.  Since both
of these have a library API now, just use the library API instead of
crypto_shash.  Even with multiple algorithms, the library-based code
still ends up being quite a bit simpler, due to how clumsy the
old-school crypto API is.  The library-based code is also more
efficient, since it avoids overheads such as indirect calls.

Acked-by: Ard Biesheuvel <ardb@kernel.org>
Link: https://lore.kernel.org/r/20250630172224.46909-3-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
Documentation/filesystems/fsverity.rst
fs/verity/Kconfig
fs/verity/enable.c
fs/verity/fsverity_private.h
fs/verity/hash_algs.c
fs/verity/open.c
fs/verity/verify.c