qemu-e2k/crypto
Daniel P. Berrange 373166636b crypto: fix initialization of gcrypt threading
The gcrypt threads implementation must be set before calling
any other gcrypt APIs, especially gcry_check_version(),
since that triggers initialization of the random pool. After
that is initialized, changes to the threads impl won't be
honoured by the random pool code. This means that gcrypt
will think thread locking is needed and so try to acquire
the random pool mutex, but this is NULL as no threads impl
was set originally. This results in a crash in the random
pool code.

For the same reasons, we must set the gcrypt threads impl
before calling gnutls_init, since that will also trigger
gcry_check_version

Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2016-10-20 12:19:35 +01:00
..
aes.c
afsplit.c
block-luks.c crypto: Switch to QEMU UUID API 2016-09-23 11:42:52 +08:00
block-luks.h
block-qcow.c
block-qcow.h
block.c
blockpriv.h
cipher-builtin.c crypto: add mode check in qcrypto_cipher_new() for cipher-builtin 2016-10-19 10:09:24 +01:00
cipher-gcrypt.c crypto: add CTR mode support 2016-10-19 10:09:24 +01:00
cipher-nettle.c crypto: add CTR mode support 2016-10-19 10:09:24 +01:00
cipher.c crypto: add CTR mode support 2016-10-19 10:09:24 +01:00
desrfb.c
hash-gcrypt.c
hash-glib.c
hash-nettle.c
hash.c
init.c crypto: fix initialization of gcrypt threading 2016-10-20 12:19:35 +01:00
ivgen-essiv.c
ivgen-essiv.h
ivgen-plain64.c
ivgen-plain64.h
ivgen-plain.c
ivgen-plain.h
ivgen.c
ivgenpriv.h
Makefile.objs
pbkdf-gcrypt.c crypto: support more hash algorithms for pbkdf 2016-09-19 16:30:45 +01:00
pbkdf-nettle.c crypto: support more hash algorithms for pbkdf 2016-09-19 16:30:45 +01:00
pbkdf-stub.c
pbkdf.c
random-gcrypt.c
random-gnutls.c
random-platform.c
secret.c
tlscreds.c
tlscredsanon.c
tlscredspriv.h
tlscredsx509.c
tlssession.c crypto: add trace points for TLS cert verification 2016-09-19 16:30:46 +01:00
trace-events crypto: add trace points for TLS cert verification 2016-09-19 16:30:46 +01:00
xts.c