diff options
author | Eric Biggers <ebiggers@google.com> | 2017-11-28 10:23:05 +0300 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2017-11-29 05:39:14 +0300 |
commit | b32a7dc8aef1882fbf983eb354837488cc9d54dc (patch) | |
tree | aa8d50f168a77514cf9f32ac98b179a0741b8fe4 /include | |
parent | d2890c3778b164fde587bc16583f3a1c87233ec5 (diff) | |
download | linux-b32a7dc8aef1882fbf983eb354837488cc9d54dc.tar.xz |
crypto: algif_aead - fix reference counting of null skcipher
In the AEAD interface for AF_ALG, the reference to the "null skcipher"
held by each tfm was being dropped in the wrong place -- when each
af_alg_ctx was freed instead of when the aead_tfm was freed. As
discovered by syzkaller, a specially crafted program could use this to
cause the null skcipher to be freed while it is still in use.
Fix it by dropping the reference in the right place.
Fixes: 72548b093ee3 ("crypto: algif_aead - copy AAD from src to dst")
Reported-by: syzbot <syzkaller@googlegroups.com>
Cc: <stable@vger.kernel.org> # v4.14+
Signed-off-by: Eric Biggers <ebiggers@google.com>
Reviewed-by: Stephan Mueller <smueller@chronox.de>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions