summaryrefslogtreecommitdiff
path: root/lib/libcrypto/asn1/x_req.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libcrypto/asn1/x_req.c')
-rw-r--r--lib/libcrypto/asn1/x_req.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/libcrypto/asn1/x_req.c b/lib/libcrypto/asn1/x_req.c
index 5ffa11e2ddf..38a6ec885cf 100644
--- a/lib/libcrypto/asn1/x_req.c
+++ b/lib/libcrypto/asn1/x_req.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: x_req.c,v 1.15 2015/02/11 04:00:39 jsing Exp $ */
+/* $OpenBSD: x_req.c,v 1.16 2018/02/20 17:06:19 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
@@ -225,3 +225,13 @@ X509_REQ_dup(X509_REQ *x)
{
return ASN1_item_dup(&X509_REQ_it, x);
}
+
+void
+X509_REQ_get0_signature(const X509_REQ *req, const ASN1_BIT_STRING **psig,
+ const X509_ALGOR **palg)
+{
+ if (psig != NULL)
+ *psig = req->signature;
+ if (palg != NULL)
+ *palg = req->sig_alg;
+}