diff options
author | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2021-05-04 08:05:44 +0200 |
---|---|---|
committer | Dr. David von Oheimb <dev@ddvo.net> | 2021-05-05 20:50:15 +0200 |
commit | a07b0bfb99169d23d2801b8aee210d98a0d12cac (patch) | |
tree | 3524678d152927fb35c84094b9e45646f6d14bc5 /include | |
parent | b0f960189b8696f878b163d7123afdb99dfdb738 (diff) |
Deprecate X509{,_CRL}_http_nbio() and simplify their definition
This is done by making use of OCSP_REQ_CTX_nbio_d2i().
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/15131)
Diffstat (limited to 'include')
-rw-r--r-- | include/openssl/x509.h.in | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/include/openssl/x509.h.in b/include/openssl/x509.h.in index 1726ecf4dc..4877fb21f9 100644 --- a/include/openssl/x509.h.in +++ b/include/openssl/x509.h.in @@ -403,13 +403,14 @@ int X509_NAME_digest(const X509_NAME *data, const EVP_MD *type, unsigned char *md, unsigned int *len); X509 *X509_load_http(const char *url, BIO *bio, BIO *rbio, int timeout); -# define X509_http_nbio(rctx, pcert) \ - ((*(pcert) = \ - OSSL_HTTP_REQ_CTX_sendreq_d2i(rctx, ASN1_ITEM_rptr(X509))) != NULL) X509_CRL *X509_CRL_load_http(const char *url, BIO *bio, BIO *rbio, int timeout); -# define X509_CRL_http_nbio(rctx, pcrl) \ - ((*(pcrl) = \ - OSSL_HTTP_REQ_CTX_sendreq_d2i(rctx, ASN1_ITEM_rptr(X509_CRL))) != NULL) +# ifndef OPENSSL_NO_DEPRECATED_3_0 +# include <openssl/ocsp.h> /* OCSP_REQ_CTX_nbio_d2i */ +# define X509_http_nbio(rctx, pcert) \ + OCSP_REQ_CTX_nbio_d2i(rctx, pcert, ASN1_ITEM_rptr(X509)) +# define X509_CRL_http_nbio(rctx, pcrl) \ + OCSP_REQ_CTX_nbio_d2i(rctx, pcrl, ASN1_ITEM_rptr(X509_CRL)) +# endif # ifndef OPENSSL_NO_STDIO X509 *d2i_X509_fp(FILE *fp, X509 **x509); |