diff options
author | Gilad Ben-Yossef <gilad@benyossef.com> | 2019-01-15 15:43:17 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2019-01-25 18:41:51 +0800 |
commit | 2b5ac17463dcb2411fed506edcf259a89bb538ba (patch) | |
tree | 2554d40c2df4f4b6b28b917a4d421fe31138cb2e /drivers/crypto/chelsio/chcr_ipsec.c | |
parent | 27649c39b56521a2c5d350604688f31db92bf1bc (diff) |
crypto: ccree - don't copy zero size ciphertext
For decryption in CBC mode we need to save the last ciphertext block
for use as the next IV. However, we were trying to do this also with
zero sized ciphertext resulting in a panic.
Fix this by only doing the copy if the ciphertext length is at least
of IV size.
Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Cc: stable@vger.kernel.org
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/chelsio/chcr_ipsec.c')
0 files changed, 0 insertions, 0 deletions