diff options
Diffstat (limited to 'crypto/openssl/demos/maurice/loadkeys.c')
-rw-r--r-- | crypto/openssl/demos/maurice/loadkeys.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/crypto/openssl/demos/maurice/loadkeys.c b/crypto/openssl/demos/maurice/loadkeys.c index 792371c..82fd22a 100644 --- a/crypto/openssl/demos/maurice/loadkeys.c +++ b/crypto/openssl/demos/maurice/loadkeys.c @@ -31,9 +31,7 @@ EVP_PKEY * ReadPublicKey(const char *certfile) if (!fp) return NULL; - x509 = (X509 *)PEM_ASN1_read ((char *(*)())d2i_X509, - PEM_STRING_X509, - fp, NULL, NULL, NULL); + x509 = PEM_read_X509(fp, NULL, 0, NULL); if (x509 == NULL) { @@ -61,10 +59,7 @@ EVP_PKEY *ReadPrivateKey(const char *keyfile) if (!fp) return NULL; - pkey = (EVP_PKEY*)PEM_ASN1_read ((char *(*)())d2i_PrivateKey, - PEM_STRING_EVP_PKEY, - fp, - NULL, NULL, NULL); + pkey = PEM_read_PrivateKey(fp, NULL, 0, NULL); fclose (fp); |