crypto: ccree - fix AEAD decrypt auth fail
authorGilad Ben-Yossef <gilad@benyossef.com>
Thu, 16 Jan 2020 10:14:38 +0000 (12:14 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 11 Feb 2020 12:35:22 +0000 (04:35 -0800)
commit70439e8b7ccfe70b810d98bb441c37e5c43ef8c1
tree8746efd06d546caf74077eeea719b61ad3638036
parent80c660892c24c867ee5b5bb367229ccfb2f2829b
crypto: ccree - fix AEAD decrypt auth fail

commit 2a6bc713f1cef32e39e3c4e6f2e1a9849da6379c upstream.

On AEAD decryption authentication failure we are suppose to
zero out the output plaintext buffer. However, we've missed
skipping the optional associated data that may prefix the
ciphertext. This commit fixes this issue.

Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Fixes: e88b27c8eaa8 ("crypto: ccree - use std api sg_zero_buffer")
Cc: stable@vger.kernel.org
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/crypto/ccree/cc_aead.c