]> git.ipfire.org Git - thirdparty/nettle.git/commitdiff
(_NETTLE_CIPHER_SEP_SET_KEY): New macro.
authorNiels Möller <nisse@lysator.liu.se>
Tue, 20 Jul 2010 20:30:18 +0000 (22:30 +0200)
committerNiels Möller <nisse@lysator.liu.se>
Tue, 20 Jul 2010 20:30:18 +0000 (22:30 +0200)
Rev: nettle/nettle-meta.h:1.7

nettle-meta.h

index be8828df749f0fa0757d300062c347ce7793f991..e3fb4e20bb49ed80594fe2393211e0c7572711b6 100644 (file)
@@ -74,6 +74,17 @@ struct nettle_cipher
   (nettle_crypt_func *) name##_decrypt,                        \
 }
 
+#define _NETTLE_CIPHER_SEP_SET_KEY(name, NAME, keysize) {\
+  #name #keysize,                                      \
+  sizeof(struct name##_ctx),                           \
+  NAME##_BLOCK_SIZE,                                   \
+  keysize / 8,                                         \
+  (nettle_set_key_func *) name##_set_encrypt_key,      \
+  (nettle_set_key_func *) name##_set_decrypt_key,      \
+  (nettle_crypt_func *) name##_crypt,                  \
+  (nettle_crypt_func *) name##_crypt,                  \
+}
+
 #define _NETTLE_CIPHER_FIX(name, NAME, keysize) {      \
   #name,                                               \
   sizeof(struct name##_ctx),                           \