crypto: atmel-aes - fix the keys zeroing on errors
authorAntoine Tenart <antoine.tenart@bootlin.com>
Fri, 23 Feb 2018 09:01:40 +0000 (10:01 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 25 May 2018 14:17:44 +0000 (16:17 +0200)
commit223ba92a80594ed6c071b39402660ee07937ac8a
tree2836764ccd9b15965e5c707cf775c1616459d818
parent173c55493b8184623f415799aac8c62d0c5574b6
crypto: atmel-aes - fix the keys zeroing on errors

[ Upstream commit 5d804a5157dbaa64872a675923ae87161165c66b ]

The Atmel AES driver uses memzero_explicit on the keys on error, but the
variable zeroed isn't the right one because of a typo. Fix this by using
the right variable.

Fixes: 89a82ef87e01 ("crypto: atmel-authenc - add support to authenc(hmac(shaX), Y(aes)) modes")
Signed-off-by: Antoine Tenart <antoine.tenart@bootlin.com>
Reviewed-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/crypto/atmel-aes.c