summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjsing <jsing@openbsd.org>2018-03-17 14:33:20 +0000
committerjsing <jsing@openbsd.org>2018-03-17 14:33:20 +0000
commit802416cf32e04323225a70f80bb1f1dd3393dc06 (patch)
treeb8e77f41bc31b592fdcdd4f9b68db399abe98871
parentProvide SSL_SESSION_get0_id_context(). (diff)
downloadwireguard-openbsd-802416cf32e04323225a70f80bb1f1dd3393dc06.tar.xz
wireguard-openbsd-802416cf32e04323225a70f80bb1f1dd3393dc06.zip
Provide X509_REVOKED_dup().
-rw-r--r--lib/libcrypto/Symbols.list1
-rw-r--r--lib/libcrypto/asn1/x_crl.c8
-rw-r--r--lib/libcrypto/x509/x509.h3
3 files changed, 10 insertions, 2 deletions
diff --git a/lib/libcrypto/Symbols.list b/lib/libcrypto/Symbols.list
index 4d108831231..eb4d1265fb3 100644
--- a/lib/libcrypto/Symbols.list
+++ b/lib/libcrypto/Symbols.list
@@ -2815,6 +2815,7 @@ X509_REQ_verify
X509_REVOKED_add1_ext_i2d
X509_REVOKED_add_ext
X509_REVOKED_delete_ext
+X509_REVOKED_dup
X509_REVOKED_free
X509_REVOKED_get0_extensions
X509_REVOKED_get0_revocationDate
diff --git a/lib/libcrypto/asn1/x_crl.c b/lib/libcrypto/asn1/x_crl.c
index b8f517d8735..e0e6cc88633 100644
--- a/lib/libcrypto/asn1/x_crl.c
+++ b/lib/libcrypto/asn1/x_crl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: x_crl.c,v 1.29 2018/02/22 16:58:45 jsing Exp $ */
+/* $OpenBSD: x_crl.c,v 1.30 2018/03/17 14:33:20 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
@@ -462,6 +462,12 @@ X509_REVOKED_free(X509_REVOKED *a)
ASN1_item_free((ASN1_VALUE *)a, &X509_REVOKED_it);
}
+X509_REVOKED *
+X509_REVOKED_dup(X509_REVOKED *a)
+{
+ return ASN1_item_dup(&X509_REVOKED_it, a);
+}
+
X509_CRL_INFO *
d2i_X509_CRL_INFO(X509_CRL_INFO **a, const unsigned char **in, long len)
{
diff --git a/lib/libcrypto/x509/x509.h b/lib/libcrypto/x509/x509.h
index f2df12f248b..2b096ed3b34 100644
--- a/lib/libcrypto/x509/x509.h
+++ b/lib/libcrypto/x509/x509.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: x509.h,v 1.41 2018/02/22 17:22:02 jsing Exp $ */
+/* $OpenBSD: x509.h,v 1.42 2018/03/17 14:33:20 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
@@ -919,6 +919,7 @@ void X509_reject_clear(X509 *x);
X509_REVOKED *X509_REVOKED_new(void);
void X509_REVOKED_free(X509_REVOKED *a);
+X509_REVOKED *X509_REVOKED_dup(X509_REVOKED *a);
X509_REVOKED *d2i_X509_REVOKED(X509_REVOKED **a, const unsigned char **in, long len);
int i2d_X509_REVOKED(X509_REVOKED *a, unsigned char **out);
extern const ASN1_ITEM X509_REVOKED_it;