qemu-e2k/crypto
Daniel P. Berrange 8b7cdba386 crypto: fix handling of iv generator hash defaults
When opening an existing LUKS volume, if the iv generator is
essiv, then the iv hash algorithm is mandatory to provide. We
must report an error if it is omitted in the cipher mode spec,
not silently default to hash 0 (md5).  If the iv generator is
not essiv, then we explicitly ignore any iv hash algorithm,
rather than report an error, for compatibility with dm-crypt.

When creating a new LUKS volume, if the iv generator is essiv
and no iv hsah algorithm is provided, we should default to
using the sha256 hash.

Reported-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2016-07-04 10:46:59 +01:00
..
Makefile.objs crypto: do an explicit check for nettle pbkdf functions 2016-03-30 14:55:11 +01:00
aes.c crypto: Clean up includes 2016-01-29 15:07:22 +00:00
afsplit.c qemu-common: stop including qemu/bswap.h from qemu-common.h 2016-05-19 16:42:28 +02:00
block-luks.c crypto: fix handling of iv generator hash defaults 2016-07-04 10:46:59 +01:00
block-luks.h crypto: implement the LUKS block encryption format 2016-03-17 16:50:40 +00:00
block-qcow.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
block-qcow.h crypto: add block encryption framework 2016-03-17 14:41:15 +00:00
block.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
blockpriv.h crypto: add block encryption framework 2016-03-17 14:41:15 +00:00
cipher-builtin.c crypto: wire up XTS mode for cipher APIs 2016-03-17 14:41:15 +00:00
cipher-gcrypt.c crypto: wire up XTS mode for cipher APIs 2016-03-17 14:41:15 +00:00
cipher-nettle.c crypto: fix cipher function signature mismatch with nettle & xts 2016-03-21 10:03:45 +00:00
cipher.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
desrfb.c crypto: Clean up includes 2016-01-29 15:07:22 +00:00
hash.c crypto: assert that qcrypto_hash_digest_len is in range 2016-06-13 12:41:17 +01:00
init.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
ivgen-essiv.c include/crypto: Include qapi-types.h or qemu/bswap.h instead of qemu-common.h 2016-03-22 22:20:16 +01:00
ivgen-essiv.h crypto: add support for generating initialization vectors 2016-03-17 14:41:14 +00:00
ivgen-plain.c include/crypto: Include qapi-types.h or qemu/bswap.h instead of qemu-common.h 2016-03-22 22:20:16 +01:00
ivgen-plain.h crypto: add support for generating initialization vectors 2016-03-17 14:41:14 +00:00
ivgen-plain64.c include/crypto: Include qapi-types.h or qemu/bswap.h instead of qemu-common.h 2016-03-22 22:20:16 +01:00
ivgen-plain64.h crypto: add support for generating initialization vectors 2016-03-17 14:41:14 +00:00
ivgen.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
ivgenpriv.h crypto: add support for generating initialization vectors 2016-03-17 14:41:14 +00:00
pbkdf-gcrypt.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
pbkdf-nettle.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
pbkdf-stub.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
pbkdf.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
random-gcrypt.c crypto: add cryptographic random byte source 2016-03-17 09:49:01 +00:00
random-gnutls.c crypto: add cryptographic random byte source 2016-03-17 09:49:01 +00:00
random-stub.c crypto: add cryptographic random byte source 2016-03-17 09:49:01 +00:00
secret.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
tlscreds.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
tlscredsanon.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
tlscredspriv.h crypto: introduce new base module for TLS credentials 2015-09-15 14:47:37 +01:00
tlscredsx509.c TLS: provide slightly more information when TLS certificate loading fails 2016-06-13 12:41:17 +01:00
tlssession.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
trace-events trace: split out trace events for crypto/ directory 2016-06-20 17:22:14 +01:00
xts.c crypto: import an implementation of the XTS cipher mode 2016-03-17 14:41:15 +00:00