diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2016-01-19 00:21:12 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2016-01-20 03:24:59 +0000 |
commit | 3aeb93486588e7dd01379c50b8fd496d55cf8858 (patch) | |
tree | e5d5793ef4786dbfac5c724e8235a3aa1ce323b2 /apps | |
parent | a8eda4312db1f98cffda38670e2d40d36566785a (diff) |
make EVP_PKEY opaque
Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'apps')
-rw-r--r-- | apps/req.c | 2 | ||||
-rw-r--r-- | apps/x509.c | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/apps/req.c b/apps/req.c index a0da788089..eddbc77839 100644 --- a/apps/req.c +++ b/apps/req.c @@ -811,7 +811,7 @@ int req_main(int argc, char **argv) fprintf(stdout, "Modulus="); #ifndef OPENSSL_NO_RSA if (EVP_PKEY_base_id(tpubkey) == EVP_PKEY_RSA) - BN_print(out, tpubkey->pkey.rsa->n); + BN_print(out, EVP_PKEY_get0_RSA(tpubkey)->n); else #endif fprintf(stdout, "Wrong Algorithm type"); diff --git a/apps/x509.c b/apps/x509.c index 37d3a71e4a..7a688a9dfe 100644 --- a/apps/x509.c +++ b/apps/x509.c @@ -731,13 +731,13 @@ int x509_main(int argc, char **argv) } BIO_printf(out, "Modulus="); #ifndef OPENSSL_NO_RSA - if (pkey->type == EVP_PKEY_RSA) - BN_print(out, pkey->pkey.rsa->n); + if (EVP_PKEY_id(pkey) == EVP_PKEY_RSA) + BN_print(out, EVP_PKEY_get0_RSA(pkey)->n); else #endif #ifndef OPENSSL_NO_DSA - if (pkey->type == EVP_PKEY_DSA) - BN_print(out, pkey->pkey.dsa->pub_key); + if (EVP_PKEY_id(pkey) == EVP_PKEY_DSA) + BN_print(out, EVP_PKEY_get0_DSA(pkey)->pub_key); else #endif BIO_printf(out, "Wrong Algorithm type"); |