aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/prov/openssl
diff options
context:
space:
mode:
authorRenĂ© Korthaus <[email protected]>2016-12-04 22:06:32 +0100
committerRenĂ© Korthaus <[email protected]>2016-12-05 10:28:38 +0100
commit8690e4e616367c12412fb56bc1826be203a4614b (patch)
treedace4204f21931d458ceeadf351428f01792f215 /src/lib/prov/openssl
parent61c4932f27c060a691ddc04fb75d227a1e8365dd (diff)
Add Public_Key::subject_public_key()
Adds new Public_Key::subject_public_key() that returns a X.509 SubjectPublicKey structure. Renames the current Public_Key::x509_subject_public_key() to public_key_bits(). BER_encode() just invokes subject_public_key().
Diffstat (limited to 'src/lib/prov/openssl')
-rw-r--r--src/lib/prov/openssl/openssl_rsa.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/prov/openssl/openssl_rsa.cpp b/src/lib/prov/openssl/openssl_rsa.cpp
index 77f74fab6..21822a627 100644
--- a/src/lib/prov/openssl/openssl_rsa.cpp
+++ b/src/lib/prov/openssl/openssl_rsa.cpp
@@ -44,7 +44,7 @@ class OpenSSL_RSA_Encryption_Operation : public PK_Ops::Encryption
OpenSSL_RSA_Encryption_Operation(const RSA_PublicKey& rsa, int pad, size_t pad_overhead) :
m_openssl_rsa(nullptr, ::RSA_free), m_padding(pad)
{
- const std::vector<byte> der = rsa.x509_subject_public_key();
+ const std::vector<byte> der = rsa.public_key_bits();
const byte* der_ptr = der.data();
m_openssl_rsa.reset(::d2i_RSAPublicKey(nullptr, &der_ptr, der.size()));
if(!m_openssl_rsa)
@@ -143,7 +143,7 @@ class OpenSSL_RSA_Verification_Operation : public PK_Ops::Verification_with_EMSA
PK_Ops::Verification_with_EMSA(emsa),
m_openssl_rsa(nullptr, ::RSA_free)
{
- const std::vector<byte> der = rsa.x509_subject_public_key();
+ const std::vector<byte> der = rsa.public_key_bits();
const byte* der_ptr = der.data();
m_openssl_rsa.reset(::d2i_RSAPublicKey(nullptr, &der_ptr, der.size()));
}