summaryrefslogtreecommitdiffstats
path: root/crypto/evp
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2012-04-07 20:22:11 +0000
committerDr. Stephen Henson <steve@openssl.org>2012-04-07 20:22:11 +0000
commit491734eb21c29807ff64fddf273f073b6bafb0b0 (patch)
tree16738086f2d1dd0c0d323250db3200709221a5ee /crypto/evp
parent4e891a191dd5467791f17fd6b473c7419ed29244 (diff)
Initial experimental support for X9.42 DH parameter format to handle
RFC5114 parameters and X9.42 DH public and private keys. (backport from HEAD)
Diffstat (limited to 'crypto/evp')
-rw-r--r--crypto/evp/evp.h1
-rw-r--r--crypto/evp/pmeth_lib.c6
2 files changed, 6 insertions, 1 deletions
diff --git a/crypto/evp/evp.h b/crypto/evp/evp.h
index 0d1b20a7d3..093cbdba5e 100644
--- a/crypto/evp/evp.h
+++ b/crypto/evp/evp.h
@@ -114,6 +114,7 @@
#define EVP_PKEY_DSA3 NID_dsaWithSHA1
#define EVP_PKEY_DSA4 NID_dsaWithSHA1_2
#define EVP_PKEY_DH NID_dhKeyAgreement
+#define EVP_PKEY_DHX NID_dhpublicnumber
#define EVP_PKEY_EC NID_X9_62_id_ecPublicKey
#define EVP_PKEY_HMAC NID_hmac
#define EVP_PKEY_CMAC NID_cmac
diff --git a/crypto/evp/pmeth_lib.c b/crypto/evp/pmeth_lib.c
index acfa7b6f87..c64f907fda 100644
--- a/crypto/evp/pmeth_lib.c
+++ b/crypto/evp/pmeth_lib.c
@@ -74,6 +74,7 @@ STACK_OF(EVP_PKEY_METHOD) *app_pkey_methods = NULL;
extern const EVP_PKEY_METHOD rsa_pkey_meth, dh_pkey_meth, dsa_pkey_meth;
extern const EVP_PKEY_METHOD ec_pkey_meth, hmac_pkey_meth, cmac_pkey_meth;
+extern const EVP_PKEY_METHOD dhx_pkey_meth;
static const EVP_PKEY_METHOD *standard_methods[] =
{
@@ -90,7 +91,10 @@ static const EVP_PKEY_METHOD *standard_methods[] =
&ec_pkey_meth,
#endif
&hmac_pkey_meth,
- &cmac_pkey_meth
+ &cmac_pkey_meth,
+#ifndef OPENSSL_NO_DH
+ &dhx_pkey_meth
+#endif
};
DECLARE_OBJ_BSEARCH_CMP_FN(const EVP_PKEY_METHOD *, const EVP_PKEY_METHOD *,