diff options
author | tb <> | 2021-11-01 08:14:36 +0000 |
---|---|---|
committer | tb <> | 2021-11-01 08:14:36 +0000 |
commit | 9e4ccc5228dcbfa0dfefbcb77f4fbc4409e63949 (patch) | |
tree | 09eaa986df5bec5fc37f0dad91370c7d06c3f62e /src/lib | |
parent | 24b324d6b70a17a56bae163dd5417bf00331ec48 (diff) | |
download | openbsd-9e4ccc5228dcbfa0dfefbcb77f4fbc4409e63949.tar.gz openbsd-9e4ccc5228dcbfa0dfefbcb77f4fbc4409e63949.tar.bz2 openbsd-9e4ccc5228dcbfa0dfefbcb77f4fbc4409e63949.zip |
Unifdef LIBRESSL_NEW_API. Now that the library is bumped, this is
no longer needed.
ok jsing
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/libcrypto/asn1/asn1.h | 4 | ||||
-rw-r--r-- | src/lib/libcrypto/bio/bio.h | 4 | ||||
-rw-r--r-- | src/lib/libcrypto/crypto.h | 4 | ||||
-rw-r--r-- | src/lib/libcrypto/evp/evp.h | 4 | ||||
-rw-r--r-- | src/lib/libcrypto/ocsp/ocsp.h | 6 | ||||
-rw-r--r-- | src/lib/libcrypto/opensslfeatures.h | 1 | ||||
-rw-r--r-- | src/lib/libcrypto/x509/x509.h | 15 | ||||
-rw-r--r-- | src/lib/libcrypto/x509/x509_set.c | 4 | ||||
-rw-r--r-- | src/lib/libcrypto/x509/x509_vfy.h | 18 | ||||
-rw-r--r-- | src/lib/libcrypto/x509/x509v3.h | 4 | ||||
-rw-r--r-- | src/lib/libssl/ssl.h | 6 |
11 files changed, 10 insertions, 60 deletions
diff --git a/src/lib/libcrypto/asn1/asn1.h b/src/lib/libcrypto/asn1/asn1.h index 43b038adaa..815256a30d 100644 --- a/src/lib/libcrypto/asn1/asn1.h +++ b/src/lib/libcrypto/asn1/asn1.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: asn1.h,v 1.55 2021/10/27 09:50:57 beck Exp $ */ | 1 | /* $OpenBSD: asn1.h,v 1.56 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -773,10 +773,8 @@ ASN1_TIME *d2i_ASN1_TIME(ASN1_TIME **a, const unsigned char **in, long len); | |||
773 | int i2d_ASN1_TIME(ASN1_TIME *a, unsigned char **out); | 773 | int i2d_ASN1_TIME(ASN1_TIME *a, unsigned char **out); |
774 | extern const ASN1_ITEM ASN1_TIME_it; | 774 | extern const ASN1_ITEM ASN1_TIME_it; |
775 | 775 | ||
776 | #if defined(LIBRESSL_NEW_API) | ||
777 | int ASN1_TIME_diff(int *pday, int *psec, const ASN1_TIME *from, | 776 | int ASN1_TIME_diff(int *pday, int *psec, const ASN1_TIME *from, |
778 | const ASN1_TIME *to); | 777 | const ASN1_TIME *to); |
779 | #endif | ||
780 | 778 | ||
781 | extern const ASN1_ITEM ASN1_OCTET_STRING_NDEF_it; | 779 | extern const ASN1_ITEM ASN1_OCTET_STRING_NDEF_it; |
782 | 780 | ||
diff --git a/src/lib/libcrypto/bio/bio.h b/src/lib/libcrypto/bio/bio.h index 735d16e6b9..78949f051e 100644 --- a/src/lib/libcrypto/bio/bio.h +++ b/src/lib/libcrypto/bio/bio.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: bio.h,v 1.46 2021/10/24 13:46:56 tb Exp $ */ | 1 | /* $OpenBSD: bio.h,v 1.47 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -607,9 +607,7 @@ int BIO_free(BIO *a); | |||
607 | int BIO_up_ref(BIO *bio); | 607 | int BIO_up_ref(BIO *bio); |
608 | void *BIO_get_data(BIO *a); | 608 | void *BIO_get_data(BIO *a); |
609 | void BIO_set_data(BIO *a, void *ptr); | 609 | void BIO_set_data(BIO *a, void *ptr); |
610 | #if defined(LIBRESSL_NEW_API) | ||
611 | int BIO_get_init(BIO *a); | 610 | int BIO_get_init(BIO *a); |
612 | #endif | ||
613 | void BIO_set_init(BIO *a, int init); | 611 | void BIO_set_init(BIO *a, int init); |
614 | int BIO_get_shutdown(BIO *a); | 612 | int BIO_get_shutdown(BIO *a); |
615 | void BIO_set_shutdown(BIO *a, int shut); | 613 | void BIO_set_shutdown(BIO *a, int shut); |
diff --git a/src/lib/libcrypto/crypto.h b/src/lib/libcrypto/crypto.h index aba5556029..ea475e3bf4 100644 --- a/src/lib/libcrypto/crypto.h +++ b/src/lib/libcrypto/crypto.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: crypto.h,v 1.51 2021/10/23 09:13:51 beck Exp $ */ | 1 | /* $OpenBSD: crypto.h,v 1.52 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -505,10 +505,8 @@ uint64_t OPENSSL_cpu_caps(void); | |||
505 | int OPENSSL_isservice(void); | 505 | int OPENSSL_isservice(void); |
506 | 506 | ||
507 | #ifndef LIBRESSL_INTERNAL | 507 | #ifndef LIBRESSL_INTERNAL |
508 | #if defined(LIBRESSL_NEW_API) | ||
509 | int FIPS_mode(void); | 508 | int FIPS_mode(void); |
510 | int FIPS_mode_set(int r); | 509 | int FIPS_mode_set(int r); |
511 | #endif | ||
512 | 510 | ||
513 | void OPENSSL_init(void); | 511 | void OPENSSL_init(void); |
514 | 512 | ||
diff --git a/src/lib/libcrypto/evp/evp.h b/src/lib/libcrypto/evp/evp.h index 4e32a794b4..3af94350f7 100644 --- a/src/lib/libcrypto/evp/evp.h +++ b/src/lib/libcrypto/evp/evp.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp.h,v 1.84 2021/10/24 13:51:07 tb Exp $ */ | 1 | /* $OpenBSD: evp.h,v 1.85 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -486,9 +486,7 @@ int EVP_MD_block_size(const EVP_MD *md); | |||
486 | unsigned long EVP_MD_flags(const EVP_MD *md); | 486 | unsigned long EVP_MD_flags(const EVP_MD *md); |
487 | 487 | ||
488 | const EVP_MD *EVP_MD_CTX_md(const EVP_MD_CTX *ctx); | 488 | const EVP_MD *EVP_MD_CTX_md(const EVP_MD_CTX *ctx); |
489 | #if defined(LIBRESSL_NEW_API) | ||
490 | void *EVP_MD_CTX_md_data(const EVP_MD_CTX *ctx); | 489 | void *EVP_MD_CTX_md_data(const EVP_MD_CTX *ctx); |
491 | #endif | ||
492 | #define EVP_MD_CTX_size(e) EVP_MD_size(EVP_MD_CTX_md(e)) | 490 | #define EVP_MD_CTX_size(e) EVP_MD_size(EVP_MD_CTX_md(e)) |
493 | #define EVP_MD_CTX_block_size(e) EVP_MD_block_size(EVP_MD_CTX_md(e)) | 491 | #define EVP_MD_CTX_block_size(e) EVP_MD_block_size(EVP_MD_CTX_md(e)) |
494 | #define EVP_MD_CTX_type(e) EVP_MD_type(EVP_MD_CTX_md(e)) | 492 | #define EVP_MD_CTX_type(e) EVP_MD_type(EVP_MD_CTX_md(e)) |
diff --git a/src/lib/libcrypto/ocsp/ocsp.h b/src/lib/libcrypto/ocsp/ocsp.h index 554d164601..f942a8a0eb 100644 --- a/src/lib/libcrypto/ocsp/ocsp.h +++ b/src/lib/libcrypto/ocsp/ocsp.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ocsp.h,v 1.17 2021/10/24 13:50:14 tb Exp $ */ | 1 | /* $OpenBSD: ocsp.h,v 1.18 2021/11/01 08:14:36 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 | ||
@@ -414,22 +414,18 @@ int OCSP_request_sign(OCSP_REQUEST *req, X509 *signer, EVP_PKEY *key, | |||
414 | int OCSP_response_status(OCSP_RESPONSE *resp); | 414 | int OCSP_response_status(OCSP_RESPONSE *resp); |
415 | OCSP_BASICRESP *OCSP_response_get1_basic(OCSP_RESPONSE *resp); | 415 | OCSP_BASICRESP *OCSP_response_get1_basic(OCSP_RESPONSE *resp); |
416 | 416 | ||
417 | #if defined(LIBRESSL_NEW_API) | ||
418 | const ASN1_OCTET_STRING *OCSP_resp_get0_signature(const OCSP_BASICRESP *bs); | 417 | const ASN1_OCTET_STRING *OCSP_resp_get0_signature(const OCSP_BASICRESP *bs); |
419 | const X509_ALGOR *OCSP_resp_get0_tbs_sigalg(const OCSP_BASICRESP *bs); | 418 | const X509_ALGOR *OCSP_resp_get0_tbs_sigalg(const OCSP_BASICRESP *bs); |
420 | const OCSP_RESPDATA *OCSP_resp_get0_respdata(const OCSP_BASICRESP *bs); | 419 | const OCSP_RESPDATA *OCSP_resp_get0_respdata(const OCSP_BASICRESP *bs); |
421 | int OCSP_resp_get0_signer(OCSP_BASICRESP *bs, X509 **signer, | 420 | int OCSP_resp_get0_signer(OCSP_BASICRESP *bs, X509 **signer, |
422 | STACK_OF(X509) *extra_certs); | 421 | STACK_OF(X509) *extra_certs); |
423 | #endif | ||
424 | 422 | ||
425 | int OCSP_resp_count(OCSP_BASICRESP *bs); | 423 | int OCSP_resp_count(OCSP_BASICRESP *bs); |
426 | OCSP_SINGLERESP *OCSP_resp_get0(OCSP_BASICRESP *bs, int idx); | 424 | OCSP_SINGLERESP *OCSP_resp_get0(OCSP_BASICRESP *bs, int idx); |
427 | #if defined(LIBRESSL_NEW_API) | ||
428 | const ASN1_GENERALIZEDTIME *OCSP_resp_get0_produced_at(const OCSP_BASICRESP *bs); | 425 | const ASN1_GENERALIZEDTIME *OCSP_resp_get0_produced_at(const OCSP_BASICRESP *bs); |
429 | const STACK_OF(X509) *OCSP_resp_get0_certs(const OCSP_BASICRESP *bs); | 426 | const STACK_OF(X509) *OCSP_resp_get0_certs(const OCSP_BASICRESP *bs); |
430 | int OCSP_resp_get0_id(const OCSP_BASICRESP *bs, | 427 | int OCSP_resp_get0_id(const OCSP_BASICRESP *bs, |
431 | const ASN1_OCTET_STRING **pid, const X509_NAME **pname); | 428 | const ASN1_OCTET_STRING **pid, const X509_NAME **pname); |
432 | #endif | ||
433 | 429 | ||
434 | int OCSP_resp_find(OCSP_BASICRESP *bs, OCSP_CERTID *id, int last); | 430 | int OCSP_resp_find(OCSP_BASICRESP *bs, OCSP_CERTID *id, int last); |
435 | int OCSP_single_get0_status(OCSP_SINGLERESP *single, int *reason, | 431 | int OCSP_single_get0_status(OCSP_SINGLERESP *single, int *reason, |
diff --git a/src/lib/libcrypto/opensslfeatures.h b/src/lib/libcrypto/opensslfeatures.h index 4b157a6e63..f16e25e782 100644 --- a/src/lib/libcrypto/opensslfeatures.h +++ b/src/lib/libcrypto/opensslfeatures.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #define LIBRESSL_HAS_TLS1_3 | 6 | #define LIBRESSL_HAS_TLS1_3 |
7 | #define LIBRESSL_HAS_DTLS1_2 | 7 | #define LIBRESSL_HAS_DTLS1_2 |
8 | 8 | ||
9 | #define LIBRESSL_NEW_API | ||
10 | #define LIBRESSL_OPAQUE_X509 | 9 | #define LIBRESSL_OPAQUE_X509 |
11 | 10 | ||
12 | #define OPENSSL_THREADS | 11 | #define OPENSSL_THREADS |
diff --git a/src/lib/libcrypto/x509/x509.h b/src/lib/libcrypto/x509/x509.h index 43b2307c8f..9a44bf30aa 100644 --- a/src/lib/libcrypto/x509/x509.h +++ b/src/lib/libcrypto/x509/x509.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: x509.h,v 1.85 2021/10/31 16:51:16 tb Exp $ */ | 1 | /* $OpenBSD: x509.h,v 1.86 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -594,9 +594,7 @@ extern "C" { | |||
594 | int X509_CRL_up_ref(X509_CRL *x); | 594 | int X509_CRL_up_ref(X509_CRL *x); |
595 | int X509_CRL_get_signature_nid(const X509_CRL *crl); | 595 | int X509_CRL_get_signature_nid(const X509_CRL *crl); |
596 | 596 | ||
597 | #if defined(LIBRESSL_NEW_API) | ||
598 | int i2d_re_X509_CRL_tbs(X509_CRL *req, unsigned char **pp); | 597 | int i2d_re_X509_CRL_tbs(X509_CRL *req, unsigned char **pp); |
599 | #endif | ||
600 | 598 | ||
601 | const STACK_OF(X509_EXTENSION) *X509_CRL_get0_extensions(const X509_CRL *crl); | 599 | const STACK_OF(X509_EXTENSION) *X509_CRL_get0_extensions(const X509_CRL *crl); |
602 | long X509_CRL_get_version(const X509_CRL *crl); | 600 | long X509_CRL_get_version(const X509_CRL *crl); |
@@ -626,12 +624,7 @@ void X509_CRL_METHOD_free(X509_CRL_METHOD *m); | |||
626 | void X509_CRL_set_meth_data(X509_CRL *crl, void *dat); | 624 | void X509_CRL_set_meth_data(X509_CRL *crl, void *dat); |
627 | void *X509_CRL_get_meth_data(X509_CRL *crl); | 625 | void *X509_CRL_get_meth_data(X509_CRL *crl); |
628 | 626 | ||
629 | #if defined(LIBRESSL_NEW_API) | ||
630 | X509_PUBKEY *X509_get_X509_PUBKEY(const X509 *x); | 627 | X509_PUBKEY *X509_get_X509_PUBKEY(const X509 *x); |
631 | #else | ||
632 | #define X509_get_X509_PUBKEY(x) (x)->cert_info->key | ||
633 | #endif | ||
634 | |||
635 | 628 | ||
636 | const char *X509_verify_cert_error_string(long n); | 629 | const char *X509_verify_cert_error_string(long n); |
637 | 630 | ||
@@ -831,12 +824,10 @@ void X509_SIG_free(X509_SIG *a); | |||
831 | X509_SIG *d2i_X509_SIG(X509_SIG **a, const unsigned char **in, long len); | 824 | X509_SIG *d2i_X509_SIG(X509_SIG **a, const unsigned char **in, long len); |
832 | int i2d_X509_SIG(X509_SIG *a, unsigned char **out); | 825 | int i2d_X509_SIG(X509_SIG *a, unsigned char **out); |
833 | extern const ASN1_ITEM X509_SIG_it; | 826 | extern const ASN1_ITEM X509_SIG_it; |
834 | #if defined(LIBRESSL_NEW_API) | ||
835 | void X509_SIG_get0(const X509_SIG *sig, const X509_ALGOR **palg, | 827 | void X509_SIG_get0(const X509_SIG *sig, const X509_ALGOR **palg, |
836 | const ASN1_OCTET_STRING **pdigest); | 828 | const ASN1_OCTET_STRING **pdigest); |
837 | void X509_SIG_getm(X509_SIG *sig, X509_ALGOR **palg, | 829 | void X509_SIG_getm(X509_SIG *sig, X509_ALGOR **palg, |
838 | ASN1_OCTET_STRING **pdigest); | 830 | ASN1_OCTET_STRING **pdigest); |
839 | #endif | ||
840 | 831 | ||
841 | X509_REQ_INFO *X509_REQ_INFO_new(void); | 832 | X509_REQ_INFO *X509_REQ_INFO_new(void); |
842 | void X509_REQ_INFO_free(X509_REQ_INFO *a); | 833 | void X509_REQ_INFO_free(X509_REQ_INFO *a); |
@@ -903,9 +894,7 @@ void *X509_get_ex_data(X509 *r, int idx); | |||
903 | int i2d_X509_AUX(X509 *a,unsigned char **pp); | 894 | int i2d_X509_AUX(X509 *a,unsigned char **pp); |
904 | X509 * d2i_X509_AUX(X509 **a,const unsigned char **pp,long length); | 895 | X509 * d2i_X509_AUX(X509 **a,const unsigned char **pp,long length); |
905 | 896 | ||
906 | #if defined(LIBRESSL_NEW_API) | ||
907 | int i2d_re_X509_tbs(X509 *x, unsigned char **pp); | 897 | int i2d_re_X509_tbs(X509 *x, unsigned char **pp); |
908 | #endif | ||
909 | 898 | ||
910 | void X509_get0_signature(const ASN1_BIT_STRING **psig, | 899 | void X509_get0_signature(const ASN1_BIT_STRING **psig, |
911 | const X509_ALGOR **palg, const X509 *x); | 900 | const X509_ALGOR **palg, const X509 *x); |
@@ -1019,10 +1008,8 @@ int X509_REQ_set_subject_name(X509_REQ *req, X509_NAME *name); | |||
1019 | X509_NAME *X509_REQ_get_subject_name(const X509_REQ *x); | 1008 | X509_NAME *X509_REQ_get_subject_name(const X509_REQ *x); |
1020 | int X509_REQ_set_pubkey(X509_REQ *x, EVP_PKEY *pkey); | 1009 | int X509_REQ_set_pubkey(X509_REQ *x, EVP_PKEY *pkey); |
1021 | EVP_PKEY * X509_REQ_get_pubkey(X509_REQ *req); | 1010 | EVP_PKEY * X509_REQ_get_pubkey(X509_REQ *req); |
1022 | #if defined(LIBRESSL_NEW_API) | ||
1023 | int i2d_re_X509_REQ_tbs(X509_REQ *req, unsigned char **pp); | 1011 | int i2d_re_X509_REQ_tbs(X509_REQ *req, unsigned char **pp); |
1024 | EVP_PKEY * X509_REQ_get0_pubkey(X509_REQ *req); | 1012 | EVP_PKEY * X509_REQ_get0_pubkey(X509_REQ *req); |
1025 | #endif | ||
1026 | int X509_REQ_extension_nid(int nid); | 1013 | int X509_REQ_extension_nid(int nid); |
1027 | int * X509_REQ_get_extension_nids(void); | 1014 | int * X509_REQ_get_extension_nids(void); |
1028 | void X509_REQ_set_extension_nids(int *nids); | 1015 | void X509_REQ_set_extension_nids(int *nids); |
diff --git a/src/lib/libcrypto/x509/x509_set.c b/src/lib/libcrypto/x509/x509_set.c index e086c021cd..c4ce8e5674 100644 --- a/src/lib/libcrypto/x509/x509_set.c +++ b/src/lib/libcrypto/x509/x509_set.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: x509_set.c,v 1.18 2021/10/21 13:02:01 tb Exp $ */ | 1 | /* $OpenBSD: x509_set.c,v 1.19 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -217,10 +217,8 @@ X509_get_signature_type(const X509 *x) | |||
217 | return EVP_PKEY_type(OBJ_obj2nid(x->sig_alg->algorithm)); | 217 | return EVP_PKEY_type(OBJ_obj2nid(x->sig_alg->algorithm)); |
218 | } | 218 | } |
219 | 219 | ||
220 | #if defined(LIBRESSL_NEW_API) | ||
221 | X509_PUBKEY * | 220 | X509_PUBKEY * |
222 | X509_get_X509_PUBKEY(const X509 *x) | 221 | X509_get_X509_PUBKEY(const X509 *x) |
223 | { | 222 | { |
224 | return x->cert_info->key; | 223 | return x->cert_info->key; |
225 | } | 224 | } |
226 | #endif | ||
diff --git a/src/lib/libcrypto/x509/x509_vfy.h b/src/lib/libcrypto/x509/x509_vfy.h index 676145cca7..61ea11b71a 100644 --- a/src/lib/libcrypto/x509/x509_vfy.h +++ b/src/lib/libcrypto/x509/x509_vfy.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: x509_vfy.h,v 1.44 2021/10/31 16:51:16 tb Exp $ */ | 1 | /* $OpenBSD: x509_vfy.h,v 1.45 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -201,10 +201,6 @@ struct x509_store_st { | |||
201 | 201 | ||
202 | int X509_STORE_set_depth(X509_STORE *store, int depth); | 202 | int X509_STORE_set_depth(X509_STORE *store, int depth); |
203 | 203 | ||
204 | #if !defined(LIBRESSL_NEW_API) | ||
205 | #define X509_STORE_set_verify_func(ctx,func) ((ctx)->verify=(func)) | ||
206 | #endif | ||
207 | |||
208 | #if defined(LIBRESSL_CRYPTO_INTERNAL) || !defined(LIBRESSL_OPAQUE_X509) | 204 | #if defined(LIBRESSL_CRYPTO_INTERNAL) || !defined(LIBRESSL_OPAQUE_X509) |
209 | /* This is the functions plus an instance of the local variables. */ | 205 | /* This is the functions plus an instance of the local variables. */ |
210 | struct x509_lookup_st { | 206 | struct x509_lookup_st { |
@@ -425,10 +421,8 @@ void X509_STORE_CTX_set_depth(X509_STORE_CTX *ctx, int depth); | |||
425 | | X509_V_FLAG_INHIBIT_ANY \ | 421 | | X509_V_FLAG_INHIBIT_ANY \ |
426 | | X509_V_FLAG_INHIBIT_MAP) | 422 | | X509_V_FLAG_INHIBIT_MAP) |
427 | 423 | ||
428 | #if defined(LIBRESSL_NEW_API) | ||
429 | X509_OBJECT *X509_OBJECT_new(void); | 424 | X509_OBJECT *X509_OBJECT_new(void); |
430 | void X509_OBJECT_free(X509_OBJECT *a); | 425 | void X509_OBJECT_free(X509_OBJECT *a); |
431 | #endif | ||
432 | int X509_OBJECT_idx_by_subject(STACK_OF(X509_OBJECT) *h, X509_LOOKUP_TYPE type, | 426 | int X509_OBJECT_idx_by_subject(STACK_OF(X509_OBJECT) *h, X509_LOOKUP_TYPE type, |
433 | X509_NAME *name); | 427 | X509_NAME *name); |
434 | X509_OBJECT *X509_OBJECT_retrieve_by_subject(STACK_OF(X509_OBJECT) *h, | 428 | X509_OBJECT *X509_OBJECT_retrieve_by_subject(STACK_OF(X509_OBJECT) *h, |
@@ -492,10 +486,8 @@ int X509_STORE_add_crl(X509_STORE *ctx, X509_CRL *x); | |||
492 | int X509_STORE_CTX_get_by_subject(X509_STORE_CTX *vs, X509_LOOKUP_TYPE type, | 486 | int X509_STORE_CTX_get_by_subject(X509_STORE_CTX *vs, X509_LOOKUP_TYPE type, |
493 | X509_NAME *name, X509_OBJECT *ret); | 487 | X509_NAME *name, X509_OBJECT *ret); |
494 | #define X509_STORE_get_by_subject X509_STORE_CTX_get_by_subject | 488 | #define X509_STORE_get_by_subject X509_STORE_CTX_get_by_subject |
495 | #if defined(LIBRESSL_NEW_API) | ||
496 | X509_OBJECT *X509_STORE_CTX_get_obj_by_subject(X509_STORE_CTX *vs, | 489 | X509_OBJECT *X509_STORE_CTX_get_obj_by_subject(X509_STORE_CTX *vs, |
497 | X509_LOOKUP_TYPE type, X509_NAME *name); | 490 | X509_LOOKUP_TYPE type, X509_NAME *name); |
498 | #endif | ||
499 | 491 | ||
500 | int X509_LOOKUP_ctrl(X509_LOOKUP *ctx, int cmd, const char *argc, | 492 | int X509_LOOKUP_ctrl(X509_LOOKUP *ctx, int cmd, const char *argc, |
501 | long argl, char **ret); | 493 | long argl, char **ret); |
@@ -530,13 +522,9 @@ void * X509_STORE_CTX_get_ex_data(X509_STORE_CTX *ctx,int idx); | |||
530 | int X509_STORE_CTX_get_error(X509_STORE_CTX *ctx); | 522 | int X509_STORE_CTX_get_error(X509_STORE_CTX *ctx); |
531 | void X509_STORE_CTX_set_error(X509_STORE_CTX *ctx,int s); | 523 | void X509_STORE_CTX_set_error(X509_STORE_CTX *ctx,int s); |
532 | int X509_STORE_CTX_get_error_depth(X509_STORE_CTX *ctx); | 524 | int X509_STORE_CTX_get_error_depth(X509_STORE_CTX *ctx); |
533 | #if defined(LIBRESSL_NEW_API) | ||
534 | void X509_STORE_CTX_set_error_depth(X509_STORE_CTX *ctx, int depth); | 525 | void X509_STORE_CTX_set_error_depth(X509_STORE_CTX *ctx, int depth); |
535 | #endif | ||
536 | X509 * X509_STORE_CTX_get_current_cert(X509_STORE_CTX *ctx); | 526 | X509 * X509_STORE_CTX_get_current_cert(X509_STORE_CTX *ctx); |
537 | #if defined(LIBRESSL_NEW_API) | ||
538 | void X509_STORE_CTX_set_current_cert(X509_STORE_CTX *ctx, X509 *x); | 527 | void X509_STORE_CTX_set_current_cert(X509_STORE_CTX *ctx, X509 *x); |
539 | #endif | ||
540 | X509 *X509_STORE_CTX_get0_current_issuer(X509_STORE_CTX *ctx); | 528 | X509 *X509_STORE_CTX_get0_current_issuer(X509_STORE_CTX *ctx); |
541 | X509_CRL *X509_STORE_CTX_get0_current_crl(X509_STORE_CTX *ctx); | 529 | X509_CRL *X509_STORE_CTX_get0_current_crl(X509_STORE_CTX *ctx); |
542 | X509_STORE_CTX *X509_STORE_CTX_get0_parent_ctx(X509_STORE_CTX *ctx); | 530 | X509_STORE_CTX *X509_STORE_CTX_get0_parent_ctx(X509_STORE_CTX *ctx); |
@@ -552,7 +540,6 @@ int X509_STORE_CTX_purpose_inherit(X509_STORE_CTX *ctx, int def_purpose, | |||
552 | void X509_STORE_CTX_set_flags(X509_STORE_CTX *ctx, unsigned long flags); | 540 | void X509_STORE_CTX_set_flags(X509_STORE_CTX *ctx, unsigned long flags); |
553 | void X509_STORE_CTX_set_time(X509_STORE_CTX *ctx, unsigned long flags, | 541 | void X509_STORE_CTX_set_time(X509_STORE_CTX *ctx, unsigned long flags, |
554 | time_t t); | 542 | time_t t); |
555 | #if defined(LIBRESSL_NEW_API) | ||
556 | void X509_STORE_CTX_set0_verified_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk); | 543 | void X509_STORE_CTX_set0_verified_chain(X509_STORE_CTX *ctx, STACK_OF(X509) *sk); |
557 | int (*X509_STORE_CTX_get_verify(X509_STORE_CTX *ctx))(X509_STORE_CTX *); | 544 | int (*X509_STORE_CTX_get_verify(X509_STORE_CTX *ctx))(X509_STORE_CTX *); |
558 | void X509_STORE_CTX_set_verify(X509_STORE_CTX *ctx, | 545 | void X509_STORE_CTX_set_verify(X509_STORE_CTX *ctx, |
@@ -560,15 +547,12 @@ void X509_STORE_CTX_set_verify(X509_STORE_CTX *ctx, | |||
560 | #define X509_STORE_set_verify_func(ctx, func) \ | 547 | #define X509_STORE_set_verify_func(ctx, func) \ |
561 | X509_STORE_set_verify((ctx), (func)) | 548 | X509_STORE_set_verify((ctx), (func)) |
562 | int (*X509_STORE_CTX_get_verify_cb(X509_STORE_CTX *ctx))(int, X509_STORE_CTX *); | 549 | int (*X509_STORE_CTX_get_verify_cb(X509_STORE_CTX *ctx))(int, X509_STORE_CTX *); |
563 | #endif | ||
564 | void X509_STORE_CTX_set_verify_cb(X509_STORE_CTX *ctx, | 550 | void X509_STORE_CTX_set_verify_cb(X509_STORE_CTX *ctx, |
565 | int (*verify_cb)(int, X509_STORE_CTX *)); | 551 | int (*verify_cb)(int, X509_STORE_CTX *)); |
566 | 552 | ||
567 | X509_POLICY_TREE *X509_STORE_CTX_get0_policy_tree(X509_STORE_CTX *ctx); | 553 | X509_POLICY_TREE *X509_STORE_CTX_get0_policy_tree(X509_STORE_CTX *ctx); |
568 | int X509_STORE_CTX_get_explicit_policy(X509_STORE_CTX *ctx); | 554 | int X509_STORE_CTX_get_explicit_policy(X509_STORE_CTX *ctx); |
569 | #if defined(LIBRESSL_NEW_API) | ||
570 | int X509_STORE_CTX_get_num_untrusted(X509_STORE_CTX *ctx); | 555 | int X509_STORE_CTX_get_num_untrusted(X509_STORE_CTX *ctx); |
571 | #endif | ||
572 | 556 | ||
573 | X509_VERIFY_PARAM *X509_STORE_CTX_get0_param(X509_STORE_CTX *ctx); | 557 | X509_VERIFY_PARAM *X509_STORE_CTX_get0_param(X509_STORE_CTX *ctx); |
574 | void X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param); | 558 | void X509_STORE_CTX_set0_param(X509_STORE_CTX *ctx, X509_VERIFY_PARAM *param); |
diff --git a/src/lib/libcrypto/x509/x509v3.h b/src/lib/libcrypto/x509/x509v3.h index 62ed038d33..2d8ab6fc6e 100644 --- a/src/lib/libcrypto/x509/x509v3.h +++ b/src/lib/libcrypto/x509/x509v3.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: x509v3.h,v 1.9 2021/10/23 17:43:06 tb Exp $ */ | 1 | /* $OpenBSD: x509v3.h,v 1.10 2021/11/01 08:14:36 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 | */ |
@@ -800,11 +800,9 @@ char *X509_PURPOSE_get0_sname(const X509_PURPOSE *xp); | |||
800 | int X509_PURPOSE_get_trust(const X509_PURPOSE *xp); | 800 | int X509_PURPOSE_get_trust(const X509_PURPOSE *xp); |
801 | void X509_PURPOSE_cleanup(void); | 801 | void X509_PURPOSE_cleanup(void); |
802 | int X509_PURPOSE_get_id(const X509_PURPOSE *); | 802 | int X509_PURPOSE_get_id(const X509_PURPOSE *); |
803 | #if defined(LIBRESSL_NEW_API) | ||
804 | uint32_t X509_get_extension_flags(X509 *x); | 803 | uint32_t X509_get_extension_flags(X509 *x); |
805 | uint32_t X509_get_key_usage(X509 *x); | 804 | uint32_t X509_get_key_usage(X509 *x); |
806 | uint32_t X509_get_extended_key_usage(X509 *x); | 805 | uint32_t X509_get_extended_key_usage(X509 *x); |
807 | #endif | ||
808 | 806 | ||
809 | STACK_OF(OPENSSL_STRING) *X509_get1_email(X509 *x); | 807 | STACK_OF(OPENSSL_STRING) *X509_get1_email(X509 *x); |
810 | STACK_OF(OPENSSL_STRING) *X509_REQ_get1_email(X509_REQ *x); | 808 | STACK_OF(OPENSSL_STRING) *X509_REQ_get1_email(X509_REQ *x); |
diff --git a/src/lib/libssl/ssl.h b/src/lib/libssl/ssl.h index 258cde67e4..e313268216 100644 --- a/src/lib/libssl/ssl.h +++ b/src/lib/libssl/ssl.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssl.h,v 1.214 2021/10/23 20:42:50 beck Exp $ */ | 1 | /* $OpenBSD: ssl.h,v 1.215 2021/11/01 08:14:36 tb Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -506,7 +506,6 @@ void SSL_set_msg_callback(SSL *ssl, void (*cb)(int write_p, int version, | |||
506 | #define SSL_CTX_set_msg_callback_arg(ctx, arg) SSL_CTX_ctrl((ctx), SSL_CTRL_SET_MSG_CALLBACK_ARG, 0, (arg)) | 506 | #define SSL_CTX_set_msg_callback_arg(ctx, arg) SSL_CTX_ctrl((ctx), SSL_CTRL_SET_MSG_CALLBACK_ARG, 0, (arg)) |
507 | #define SSL_set_msg_callback_arg(ssl, arg) SSL_ctrl((ssl), SSL_CTRL_SET_MSG_CALLBACK_ARG, 0, (arg)) | 507 | #define SSL_set_msg_callback_arg(ssl, arg) SSL_ctrl((ssl), SSL_CTRL_SET_MSG_CALLBACK_ARG, 0, (arg)) |
508 | typedef void (*SSL_CTX_keylog_cb_func)(const SSL *ssl, const char *line); | 508 | typedef void (*SSL_CTX_keylog_cb_func)(const SSL *ssl, const char *line); |
509 | #if defined(LIBRESSL_NEW_API) | ||
510 | void SSL_CTX_set_keylog_callback(SSL_CTX *ctx, SSL_CTX_keylog_cb_func cb); | 509 | void SSL_CTX_set_keylog_callback(SSL_CTX *ctx, SSL_CTX_keylog_cb_func cb); |
511 | SSL_CTX_keylog_cb_func SSL_CTX_get_keylog_callback(const SSL_CTX *ctx); | 510 | SSL_CTX_keylog_cb_func SSL_CTX_get_keylog_callback(const SSL_CTX *ctx); |
512 | int SSL_set_num_tickets(SSL *s, size_t num_tickets); | 511 | int SSL_set_num_tickets(SSL *s, size_t num_tickets); |
@@ -514,7 +513,6 @@ size_t SSL_get_num_tickets(const SSL *s); | |||
514 | int SSL_CTX_set_num_tickets(SSL_CTX *ctx, size_t num_tickets); | 513 | int SSL_CTX_set_num_tickets(SSL_CTX *ctx, size_t num_tickets); |
515 | size_t SSL_CTX_get_num_tickets(const SSL_CTX *ctx); | 514 | size_t SSL_CTX_get_num_tickets(const SSL_CTX *ctx); |
516 | STACK_OF(X509) *SSL_get0_verified_chain(const SSL *s); | 515 | STACK_OF(X509) *SSL_get0_verified_chain(const SSL *s); |
517 | #endif | ||
518 | 516 | ||
519 | #ifndef LIBRESSL_INTERNAL | 517 | #ifndef LIBRESSL_INTERNAL |
520 | struct ssl_aead_ctx_st; | 518 | struct ssl_aead_ctx_st; |
@@ -1294,11 +1292,9 @@ int SSL_is_server(const SSL *s); | |||
1294 | int SSL_read(SSL *ssl, void *buf, int num); | 1292 | int SSL_read(SSL *ssl, void *buf, int num); |
1295 | int SSL_peek(SSL *ssl, void *buf, int num); | 1293 | int SSL_peek(SSL *ssl, void *buf, int num); |
1296 | int SSL_write(SSL *ssl, const void *buf, int num); | 1294 | int SSL_write(SSL *ssl, const void *buf, int num); |
1297 | #if defined(LIBRESSL_NEW_API) | ||
1298 | int SSL_read_ex(SSL *ssl, void *buf, size_t num, size_t *bytes_read); | 1295 | int SSL_read_ex(SSL *ssl, void *buf, size_t num, size_t *bytes_read); |
1299 | int SSL_peek_ex(SSL *ssl, void *buf, size_t num, size_t *bytes_peeked); | 1296 | int SSL_peek_ex(SSL *ssl, void *buf, size_t num, size_t *bytes_peeked); |
1300 | int SSL_write_ex(SSL *ssl, const void *buf, size_t num, size_t *bytes_written); | 1297 | int SSL_write_ex(SSL *ssl, const void *buf, size_t num, size_t *bytes_written); |
1301 | #endif | ||
1302 | 1298 | ||
1303 | #if defined(LIBRESSL_HAS_TLS1_3) || defined(LIBRESSL_INTERNAL) | 1299 | #if defined(LIBRESSL_HAS_TLS1_3) || defined(LIBRESSL_INTERNAL) |
1304 | uint32_t SSL_CTX_get_max_early_data(const SSL_CTX *ctx); | 1300 | uint32_t SSL_CTX_get_max_early_data(const SSL_CTX *ctx); |