[PATCH] crypto: arm64/ghash - Fix incorrect output from ghash-neon
Herbert Xu
herbert at gondor.apana.org.au
Tue Dec 9 15:24:31 PST 2025
On Tue, Dec 09, 2025 at 02:34:17PM -0800, Eric Biggers wrote:
> Commit 9a7c987fb92b ("crypto: arm64/ghash - Use API partial block
> handling") made ghash_finup() pass the wrong buffer to
> ghash_do_simd_update(). As a result, ghash-neon now produces incorrect
> outputs when the message length isn't divisible by 16 bytes. Fix this.
>
> (I didn't notice this earlier because this code is reached only on CPUs
> that support NEON but not PMULL. I haven't yet found a way to get
> qemu-system-aarch64 to emulate that configuration.)
>
> Fixes: 9a7c987fb92b ("crypto: arm64/ghash - Use API partial block handling")
> Cc: stable at vger.kernel.org
> Reported-by: Diederik de Haas <diederik at cknow-tech.com>
> Closes: https://lore.kernel.org/linux-crypto/DETXT7QI62KE.F3CGH2VWX1SC@cknow-tech.com/
> Signed-off-by: Eric Biggers <ebiggers at kernel.org>
> ---
>
> If it's okay, I'd like to just take this via libcrypto-fixes.
>
> arch/arm64/crypto/ghash-ce-glue.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Thanks for catching this!
Acked-by: Herbert Xu <herbert at gondor.apana.org.au>
--
Email: Herbert Xu <herbert at gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
More information about the linux-arm-kernel
mailing list