summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lib/libcrypto/Makefile3
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_asn.c4
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_cl.c4
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_ext.c3
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_lib.c4
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_local.h71
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_prn.c4
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_srv.c4
-rw-r--r--src/lib/libcrypto/ocsp/ocsp_vfy.c3
-rw-r--r--src/lib/libcrypto/x509/x509_ocsp.c4
10 files changed, 95 insertions, 9 deletions
diff --git a/src/lib/libcrypto/Makefile b/src/lib/libcrypto/Makefile
index 71e16cc2b0..7e7fff3175 100644
--- a/src/lib/libcrypto/Makefile
+++ b/src/lib/libcrypto/Makefile
@@ -1,4 +1,4 @@
1# $OpenBSD: Makefile,v 1.66 2022/01/07 09:35:36 tb Exp $ 1# $OpenBSD: Makefile,v 1.67 2022/01/07 09:45:52 tb Exp $
2 2
3LIB= crypto 3LIB= crypto
4LIBREBUILD=y 4LIBREBUILD=y
@@ -40,6 +40,7 @@ CFLAGS+= -I${LCRYPTO_SRC}/ecdsa
40CFLAGS+= -I${LCRYPTO_SRC}/evp 40CFLAGS+= -I${LCRYPTO_SRC}/evp
41CFLAGS+= -I${LCRYPTO_SRC}/hmac 41CFLAGS+= -I${LCRYPTO_SRC}/hmac
42CFLAGS+= -I${LCRYPTO_SRC}/modes 42CFLAGS+= -I${LCRYPTO_SRC}/modes
43CFLAGS+= -I${LCRYPTO_SRC}/ocsp
43CFLAGS+= -I${LCRYPTO_SRC}/x509 44CFLAGS+= -I${LCRYPTO_SRC}/x509
44 45
45VERSION_SCRIPT= Symbols.map 46VERSION_SCRIPT= Symbols.map
diff --git a/src/lib/libcrypto/ocsp/ocsp_asn.c b/src/lib/libcrypto/ocsp/ocsp_asn.c
index bb58ca79ab..3f00fca105 100644
--- a/src/lib/libcrypto/ocsp/ocsp_asn.c
+++ b/src/lib/libcrypto/ocsp/ocsp_asn.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_asn.c,v 1.9 2016/11/04 18:35:30 jsing Exp $ */ 1/* $OpenBSD: ocsp_asn.c,v 1.10 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
3 * project 2000. 3 * project 2000.
4 */ 4 */
@@ -59,6 +59,8 @@
59#include <openssl/asn1t.h> 59#include <openssl/asn1t.h>
60#include <openssl/ocsp.h> 60#include <openssl/ocsp.h>
61 61
62#include "ocsp_local.h"
63
62static const ASN1_TEMPLATE OCSP_SIGNATURE_seq_tt[] = { 64static const ASN1_TEMPLATE OCSP_SIGNATURE_seq_tt[] = {
63 { 65 {
64 .flags = 0, 66 .flags = 0,
diff --git a/src/lib/libcrypto/ocsp/ocsp_cl.c b/src/lib/libcrypto/ocsp/ocsp_cl.c
index 394056e55d..bcc484c3c5 100644
--- a/src/lib/libcrypto/ocsp/ocsp_cl.c
+++ b/src/lib/libcrypto/ocsp/ocsp_cl.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_cl.c,v 1.20 2021/11/24 19:27:03 tb Exp $ */ 1/* $OpenBSD: ocsp_cl.c,v 1.21 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL 2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL
3 * project. */ 3 * project. */
4 4
@@ -71,6 +71,8 @@
71#include <openssl/x509.h> 71#include <openssl/x509.h>
72#include <openssl/x509v3.h> 72#include <openssl/x509v3.h>
73 73
74#include "ocsp_local.h"
75
74/* Utility functions related to sending OCSP requests and extracting 76/* Utility functions related to sending OCSP requests and extracting
75 * relevant information from the response. 77 * relevant information from the response.
76 */ 78 */
diff --git a/src/lib/libcrypto/ocsp/ocsp_ext.c b/src/lib/libcrypto/ocsp/ocsp_ext.c
index c48843492d..1400ad70d5 100644
--- a/src/lib/libcrypto/ocsp/ocsp_ext.c
+++ b/src/lib/libcrypto/ocsp/ocsp_ext.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_ext.c,v 1.19 2021/11/01 20:53:08 tb Exp $ */ 1/* $OpenBSD: ocsp_ext.c,v 1.20 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL 2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL
3 * project. */ 3 * project. */
4 4
@@ -70,6 +70,7 @@
70#include <openssl/x509.h> 70#include <openssl/x509.h>
71#include <openssl/x509v3.h> 71#include <openssl/x509v3.h>
72 72
73#include "ocsp_local.h"
73#include "x509_lcl.h" 74#include "x509_lcl.h"
74 75
75/* Standard wrapper functions for extensions */ 76/* Standard wrapper functions for extensions */
diff --git a/src/lib/libcrypto/ocsp/ocsp_lib.c b/src/lib/libcrypto/ocsp/ocsp_lib.c
index 53d516020d..8081a1ce85 100644
--- a/src/lib/libcrypto/ocsp/ocsp_lib.c
+++ b/src/lib/libcrypto/ocsp/ocsp_lib.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_lib.c,v 1.23 2018/08/24 20:03:21 tb Exp $ */ 1/* $OpenBSD: ocsp_lib.c,v 1.24 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL 2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL
3 * project. */ 3 * project. */
4 4
@@ -74,6 +74,8 @@
74#include <openssl/x509.h> 74#include <openssl/x509.h>
75#include <openssl/x509v3.h> 75#include <openssl/x509v3.h>
76 76
77#include "ocsp_local.h"
78
77/* Convert a certificate and its issuer to an OCSP_CERTID */ 79/* Convert a certificate and its issuer to an OCSP_CERTID */
78 80
79OCSP_CERTID * 81OCSP_CERTID *
diff --git a/src/lib/libcrypto/ocsp/ocsp_local.h b/src/lib/libcrypto/ocsp/ocsp_local.h
new file mode 100644
index 0000000000..5651f9f795
--- /dev/null
+++ b/src/lib/libcrypto/ocsp/ocsp_local.h
@@ -0,0 +1,71 @@
1/* $OpenBSD: ocsp_local.h,v 1.1 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL
3 * project. */
4
5/* History:
6 This file was transfered to Richard Levitte from CertCo by Kathy
7 Weinhold in mid-spring 2000 to be included in OpenSSL or released
8 as a patch kit. */
9
10/* ====================================================================
11 * Copyright (c) 1998-2000 The OpenSSL Project. All rights reserved.
12 *
13 * Redistribution and use in source and binary forms, with or without
14 * modification, are permitted provided that the following conditions
15 * are met:
16 *
17 * 1. Redistributions of source code must retain the above copyright
18 * notice, this list of conditions and the following disclaimer.
19 *
20 * 2. Redistributions in binary form must reproduce the above copyright
21 * notice, this list of conditions and the following disclaimer in
22 * the documentation and/or other materials provided with the
23 * distribution.
24 *
25 * 3. All advertising materials mentioning features or use of this
26 * software must display the following acknowledgment:
27 * "This product includes software developed by the OpenSSL Project
28 * for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
29 *
30 * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
31 * endorse or promote products derived from this software without
32 * prior written permission. For written permission, please contact
33 * openssl-core@openssl.org.
34 *
35 * 5. Products derived from this software may not be called "OpenSSL"
36 * nor may "OpenSSL" appear in their names without prior written
37 * permission of the OpenSSL Project.
38 *
39 * 6. Redistributions of any form whatsoever must retain the following
40 * acknowledgment:
41 * "This product includes software developed by the OpenSSL Project
42 * for use in the OpenSSL Toolkit (http://www.openssl.org/)"
43 *
44 * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
45 * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
46 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
47 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR
48 * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
49 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
50 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
51 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
52 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
53 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
54 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
55 * OF THE POSSIBILITY OF SUCH DAMAGE.
56 * ====================================================================
57 *
58 * This product includes cryptographic software written by Eric Young
59 * (eay@cryptsoft.com). This product includes software written by Tim
60 * Hudson (tjh@cryptsoft.com).
61 *
62 */
63
64#ifndef HEADER_OCSP_LOCAL_H
65#define HEADER_OCSP_LOCAL_H
66
67__BEGIN_HIDDEN_DECLS
68
69__END_HIDDEN_DECLS
70
71#endif /* !HEADER_OCSP_LOCAL_H */
diff --git a/src/lib/libcrypto/ocsp/ocsp_prn.c b/src/lib/libcrypto/ocsp/ocsp_prn.c
index 37d033adb6..fecd14bbfd 100644
--- a/src/lib/libcrypto/ocsp/ocsp_prn.c
+++ b/src/lib/libcrypto/ocsp/ocsp_prn.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_prn.c,v 1.8 2015/07/16 02:16:19 miod Exp $ */ 1/* $OpenBSD: ocsp_prn.c,v 1.9 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL 2/* Written by Tom Titchener <Tom_Titchener@groove.net> for the OpenSSL
3 * project. */ 3 * project. */
4 4
@@ -66,6 +66,8 @@
66#include <openssl/ocsp.h> 66#include <openssl/ocsp.h>
67#include <openssl/pem.h> 67#include <openssl/pem.h>
68 68
69#include "ocsp_local.h"
70
69static int 71static int
70ocsp_certid_print(BIO *bp, OCSP_CERTID* a, int indent) 72ocsp_certid_print(BIO *bp, OCSP_CERTID* a, int indent)
71{ 73{
diff --git a/src/lib/libcrypto/ocsp/ocsp_srv.c b/src/lib/libcrypto/ocsp/ocsp_srv.c
index 5c9ac4d807..d23520708c 100644
--- a/src/lib/libcrypto/ocsp/ocsp_srv.c
+++ b/src/lib/libcrypto/ocsp/ocsp_srv.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_srv.c,v 1.11 2021/11/01 20:53:08 tb Exp $ */ 1/* $OpenBSD: ocsp_srv.c,v 1.12 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
3 * project 2001. 3 * project 2001.
4 */ 4 */
@@ -65,6 +65,8 @@
65#include <openssl/x509.h> 65#include <openssl/x509.h>
66#include <openssl/x509v3.h> 66#include <openssl/x509v3.h>
67 67
68#include "ocsp_local.h"
69
68/* Utility functions related to sending OCSP responses and extracting 70/* Utility functions related to sending OCSP responses and extracting
69 * relevant information from the request. 71 * relevant information from the request.
70 */ 72 */
diff --git a/src/lib/libcrypto/ocsp/ocsp_vfy.c b/src/lib/libcrypto/ocsp/ocsp_vfy.c
index f3b41032d8..f5597d0245 100644
--- a/src/lib/libcrypto/ocsp/ocsp_vfy.c
+++ b/src/lib/libcrypto/ocsp/ocsp_vfy.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ocsp_vfy.c,v 1.19 2021/11/24 19:33:24 tb Exp $ */ 1/* $OpenBSD: ocsp_vfy.c,v 1.20 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
3 * project 2000. 3 * project 2000.
4 */ 4 */
@@ -60,6 +60,7 @@
60#include <openssl/err.h> 60#include <openssl/err.h>
61#include <string.h> 61#include <string.h>
62 62
63#include "ocsp_local.h"
63#include "x509_lcl.h" 64#include "x509_lcl.h"
64 65
65static int ocsp_find_signer(X509 **psigner, OCSP_BASICRESP *bs, 66static int ocsp_find_signer(X509 **psigner, OCSP_BASICRESP *bs,
diff --git a/src/lib/libcrypto/x509/x509_ocsp.c b/src/lib/libcrypto/x509/x509_ocsp.c
index 59a2e972ca..cc55d9390d 100644
--- a/src/lib/libcrypto/x509/x509_ocsp.c
+++ b/src/lib/libcrypto/x509/x509_ocsp.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: x509_ocsp.c,v 1.1 2020/06/04 15:19:31 jsing Exp $ */ 1/* $OpenBSD: x509_ocsp.c,v 1.2 2022/01/07 09:45:52 tb Exp $ */
2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
3 * project 1999. 3 * project 1999.
4 */ 4 */
@@ -69,6 +69,8 @@
69#include <openssl/ocsp.h> 69#include <openssl/ocsp.h>
70#include <openssl/x509v3.h> 70#include <openssl/x509v3.h>
71 71
72#include "ocsp_local.h"
73
72/* OCSP extensions and a couple of CRL entry extensions 74/* OCSP extensions and a couple of CRL entry extensions
73 */ 75 */
74 76