]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
crypto: aead,cipher - zeroize key buffer after use
authorHailey Mothershead <hailmo@amazon.com>
Mon, 15 Apr 2024 22:19:15 +0000 (22:19 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 11 Jul 2024 10:49:04 +0000 (12:49 +0200)
commitb502d4a08875ea2b4ea5d5b28dc7c991c8b90cfb
treed5fbf925941f8e373dc74aa329c856b10233903a
parent1ee644460fe8373a6655df54ab653e7d304d82b6
crypto: aead,cipher - zeroize key buffer after use

[ Upstream commit 23e4099bdc3c8381992f9eb975c79196d6755210 ]

I.G 9.7.B for FIPS 140-3 specifies that variables temporarily holding
cryptographic information should be zeroized once they are no longer
needed. Accomplish this by using kfree_sensitive for buffers that
previously held the private key.

Signed-off-by: Hailey Mothershead <hailmo@amazon.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
crypto/aead.c
crypto/cipher.c