aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pubkey/pubkey.cpp
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2016-01-04 02:42:24 -0500
committerJack Lloyd <[email protected]>2016-01-04 02:42:24 -0500
commitb2722fd321dcefcfc7111cc8185bb9cdc3f5e112 (patch)
treed8c184508348206591f5eb8dd1680239c6fa18b0 /src/lib/pubkey/pubkey.cpp
parente61e64e37393be1827a9db27c95e4cc9d4af43dd (diff)
Add ECDH via OpenSSL
Expose provider param in PK_Key_Agreement API Handle multiple providers in key agreement tests Fix some funky formatting of P-521 EC points in ecdh.vec which was being rejected by OpenSSL; for whatever reason the CAVS file had the affine coords with far more leading zeros than necessary.
Diffstat (limited to 'src/lib/pubkey/pubkey.cpp')
-rw-r--r--src/lib/pubkey/pubkey.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/pubkey/pubkey.cpp b/src/lib/pubkey/pubkey.cpp
index e870dfdec..3d09e44d5 100644
--- a/src/lib/pubkey/pubkey.cpp
+++ b/src/lib/pubkey/pubkey.cpp
@@ -99,9 +99,11 @@ secure_vector<byte> PK_KEM_Decryptor::decrypt(const byte encap_key[],
salt, salt_len);
}
-PK_Key_Agreement::PK_Key_Agreement(const Private_Key& key, const std::string& kdf)
+PK_Key_Agreement::PK_Key_Agreement(const Private_Key& key,
+ const std::string& kdf,
+ const std::string& provider)
{
- m_op.reset(get_pk_op<PK_Ops::Key_Agreement>("Key agreement", key, kdf));
+ m_op.reset(get_pk_op<PK_Ops::Key_Agreement>("Key agreement", key, kdf, provider));
}
SymmetricKey PK_Key_Agreement::derive_key(size_t key_len,