]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
cryptodev: added missing macro [ci skip]
authorNikos Mavrogiannopoulos <nmav@redhat.com>
Wed, 7 Mar 2018 15:14:51 +0000 (16:14 +0100)
committerNikos Mavrogiannopoulos <nmav@redhat.com>
Wed, 7 Mar 2018 15:14:59 +0000 (16:14 +0100)
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
lib/accelerated/cryptodev.h

index b77fa6e89eb06c773c1a051d3f402a7b6535be13..78b81cbd533b3bef2d321eb85c4e36f3152c2afb 100644 (file)
@@ -1,5 +1,9 @@
 extern int _gnutls_cryptodev_fd;
 
+#define CHECK_AES_KEYSIZE(s) \
+       if (s != 16 && s != 24 && s != 32) \
+               return GNUTLS_E_INVALID_REQUEST
+
 void _gnutls_cryptodev_deinit(void);
 int _gnutls_cryptodev_init(void);
 int _cryptodev_register_gcm_crypto(int cfd);