-/* $OpenBSD: x509.h,v 1.37 2018/02/22 17:01:44 jsing Exp $ */
+/* $OpenBSD: x509.h,v 1.38 2018/02/22 17:05:35 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
ASN1_TIME *X509_getm_notAfter(const X509 *x);
int X509_set_pubkey(X509 *x, EVP_PKEY *pkey);
EVP_PKEY * X509_get_pubkey(X509 *x);
-ASN1_BIT_STRING * X509_get0_pubkey_bitstr(const X509 *x);
+EVP_PKEY * X509_get0_pubkey(X509 *x);
+ASN1_BIT_STRING *X509_get0_pubkey_bitstr(const X509 *x);
int X509_certificate_type(X509 *x,EVP_PKEY *pubkey /* optional */);
int X509_REQ_set_version(X509_REQ *x,long version);
-/* $OpenBSD: x509_cmp.c,v 1.27 2017/01/29 17:49:23 beck Exp $ */
+/* $OpenBSD: x509_cmp.c,v 1.28 2018/02/22 17:05:35 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
EVP_PKEY *
X509_get_pubkey(X509 *x)
{
- if ((x == NULL) || (x->cert_info == NULL))
+ if (x == NULL || x->cert_info == NULL)
return (NULL);
return (X509_PUBKEY_get(x->cert_info->key));
}
+EVP_PKEY *
+X509_get0_pubkey(X509 *x)
+{
+ return X509_get_pubkey(x);
+}
+
ASN1_BIT_STRING *
X509_get0_pubkey_bitstr(const X509 *x)
{