added XOF dependencies of bliss and ntru plugins
authorAndreas Steffen <andreas.steffen@strongswan.org>
Tue, 18 Oct 2016 06:33:35 +0000 (08:33 +0200)
committerAndreas Steffen <andreas.steffen@strongswan.org>
Tue, 18 Oct 2016 14:28:43 +0000 (16:28 +0200)
src/libstrongswan/plugins/bliss/bliss_plugin.c
src/libstrongswan/plugins/ntru/ntru_plugin.c

index 4adcf1e..cdf3e96 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2014 Andreas Steffen
+ * Copyright (C) 2014-2016 Andreas Steffen
  * HSR Hochschule fuer Technik Rapperswil
  *
  * This program is free software; you can redistribute it and/or modify it
@@ -50,6 +50,8 @@ METHOD(plugin_t, get_features, int,
                PLUGIN_REGISTER(PRIVKEY_GEN, bliss_private_key_gen, FALSE),
                        PLUGIN_PROVIDE(PRIVKEY_GEN, KEY_BLISS),
                                PLUGIN_DEPENDS(RNG, RNG_TRUE),
+                               PLUGIN_SDEPEND(XOF, XOF_MGF1_SHA1),
+                               PLUGIN_SDEPEND(XOF, XOF_MGF1_SHA256),
                PLUGIN_REGISTER(PUBKEY, bliss_public_key_load, TRUE),
                        PLUGIN_PROVIDE(PUBKEY, KEY_BLISS),
                PLUGIN_REGISTER(PUBKEY, bliss_public_key_load, TRUE),
@@ -57,29 +59,41 @@ METHOD(plugin_t, get_features, int,
                /* signature schemes, private */
                PLUGIN_PROVIDE(PRIVKEY_SIGN, SIGN_BLISS_WITH_SHA2_256),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA256),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PRIVKEY_SIGN, SIGN_BLISS_WITH_SHA2_384),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA384),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PRIVKEY_SIGN, SIGN_BLISS_WITH_SHA2_512),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA512),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PRIVKEY_SIGN, SIGN_BLISS_WITH_SHA3_256),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA3_256),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PRIVKEY_SIGN, SIGN_BLISS_WITH_SHA3_384),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA3_384),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PRIVKEY_SIGN, SIGN_BLISS_WITH_SHA3_512),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA3_512),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                /* signature verification schemes */
                PLUGIN_PROVIDE(PUBKEY_VERIFY, SIGN_BLISS_WITH_SHA2_256),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA256),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PUBKEY_VERIFY, SIGN_BLISS_WITH_SHA2_384),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA384),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PUBKEY_VERIFY, SIGN_BLISS_WITH_SHA2_512),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA512),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PUBKEY_VERIFY, SIGN_BLISS_WITH_SHA3_256),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA3_256),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PUBKEY_VERIFY, SIGN_BLISS_WITH_SHA3_384),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA3_384),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
                PLUGIN_PROVIDE(PUBKEY_VERIFY, SIGN_BLISS_WITH_SHA3_512),
                        PLUGIN_DEPENDS(HASHER, HASH_SHA3_512),
+                       PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA512),
        };
        *features = f;
 
index 66be7c7..dc6bd31 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2013 Andreas Steffen
+ * Copyright (C) 2013-2016 Andreas Steffen
  * HSR Hochschule fuer Technik Rapperswil
  *
  * This program is free software; you can redistribute it and/or modify it
@@ -43,13 +43,21 @@ METHOD(plugin_t, get_features, int,
        static plugin_feature_t f[] = {
                PLUGIN_REGISTER(DH, ntru_ke_create),
                        PLUGIN_PROVIDE(DH, NTRU_112_BIT),
+                               PLUGIN_DEPENDS(RNG, RNG_TRUE),
+                               PLUGIN_DEPENDS(SIGNER, AUTH_HMAC_SHA2_256_256),
+                               PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA1),
                        PLUGIN_PROVIDE(DH, NTRU_128_BIT),
+                               PLUGIN_DEPENDS(RNG, RNG_TRUE),
+                               PLUGIN_DEPENDS(SIGNER, AUTH_HMAC_SHA2_256_256),
+                               PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA1),
                        PLUGIN_PROVIDE(DH, NTRU_192_BIT),
+                               PLUGIN_DEPENDS(RNG, RNG_TRUE),
+                               PLUGIN_DEPENDS(SIGNER, AUTH_HMAC_SHA2_256_256),
+                               PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA256),
                        PLUGIN_PROVIDE(DH, NTRU_256_BIT),
                                PLUGIN_DEPENDS(RNG, RNG_TRUE),
                                PLUGIN_DEPENDS(SIGNER, AUTH_HMAC_SHA2_256_256),
-                               PLUGIN_DEPENDS(HASHER, HASH_SHA256),
-                               PLUGIN_SDEPEND(HASHER, HASH_SHA1)
+                               PLUGIN_DEPENDS(XOF, XOF_MGF1_SHA256),
        };
        *features = f;