crypto: drbg - always try to free Jitter RNG instance
authorStephan Müller <smueller@chronox.de>
Sun, 7 Jun 2020 13:20:26 +0000 (15:20 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 25 Jun 2022 09:46:41 +0000 (11:46 +0200)
commiteb86176aea774689fcfa9afb59b9ae7c6151d0e2
treeafd2eea454f6ddb5bd5680e02965622d876653f7
parent31a5afe0696ca7c55ddc8a4b87c02863013f14d0
crypto: drbg - always try to free Jitter RNG instance

commit 819966c06b759022e9932f328284314d9272b9f3 upstream.

The Jitter RNG is unconditionally allocated as a seed source follwoing
the patch 97f2650e5040. Thus, the instance must always be deallocated.

Reported-by: syzbot+2e635807decef724a1fa@syzkaller.appspotmail.com
Fixes: 97f2650e5040 ("crypto: drbg - always seeded with SP800-90B ...")
Signed-off-by: Stephan Mueller <smueller@chronox.de>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
crypto/drbg.c