aboutsummaryrefslogtreecommitdiff
path: root/crypto/cipher.c
diff options
context:
space:
mode:
authorDaniel P. Berrangé <berrange@redhat.com>2021-06-29 13:25:55 +0100
committerDaniel P. Berrangé <berrange@redhat.com>2021-07-14 14:15:52 +0100
commit3d2b61ffcd4a5a8f5bfcdb2be5eac1a37f5caaa1 (patch)
treee063f98f047fb73ff0734ea9fc6ae7c093db935a /crypto/cipher.c
parentcc4c7c738297958b3d1d16269f57d71d22f5a9ff (diff)
crypto: add gnutls cipher provider
Add an implementation of the QEMU cipher APIs to the gnutls crypto backend. XTS support is only available for gnutls version >= 3.6.8. Since ECB mode is not exposed by gnutls APIs, we can't use the private XTS code for compatibility. Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Diffstat (limited to 'crypto/cipher.c')
-rw-r--r--crypto/cipher.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/cipher.c b/crypto/cipher.c
index 1f5528be49..74b09a5b26 100644
--- a/crypto/cipher.c
+++ b/crypto/cipher.c
@@ -136,6 +136,8 @@ qcrypto_cipher_validate_key_length(QCryptoCipherAlgorithm alg,
#include "cipher-gcrypt.c.inc"
#elif defined CONFIG_NETTLE
#include "cipher-nettle.c.inc"
+#elif defined CONFIG_GNUTLS_CRYPTO
+#include "cipher-gnutls.c.inc"
#else
#include "cipher-builtin.c.inc"
#endif