Generalize the HTTP client so far implemented mostly in crypto/ocsp/ocsp_ht.c
authorDr. David von Oheimb <David.von.Oheimb@siemens.com>
Wed, 30 Oct 2019 22:39:35 +0000 (23:39 +0100)
committerDr. David von Oheimb <David.von.Oheimb@siemens.com>
Mon, 10 Feb 2020 15:49:37 +0000 (16:49 +0100)
commit29f178bddfdbd11218fbcba0b8060297696968e3
treea44efcd919c122d9c6ff38c61b14676b002aa010
parentbcbb30afe2ef51c7affaaa7ce4db67e26e7ff6b7
Generalize the HTTP client so far implemented mostly in crypto/ocsp/ocsp_ht.c
The new client has become an independent libcrpyto module in crypto/http/ and
* can handle any types of requests and responses (ASN.1-encoded and plain)
* does not include potentially busy loops when waiting for responses but
* makes use of a new timeout mechanism integrated with socket-based BIO
* supports the use of HTTP proxies and TLS, including HTTPS over proxies
* supports HTTP redirection via codes 301 and 302 for GET requests
* returns more useful diagnostics in various error situations
Also adapts - and strongly simplifies - hitherto uses of HTTP in crypto/ocsp/,
crypto/x509/x_all.c, apps/lib/apps.c, and apps/{ocsp,s_client,s_server}.c

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: David von Oheimb <david.von.oheimb@siemens.com>
(Merged from https://github.com/openssl/openssl/pull/10667)
45 files changed:
apps/include/apps.h
apps/lib/apps.c
apps/ocsp.c
apps/s_client.c
apps/s_server.c
crypto/build.info
crypto/cmp/cmp_ctx.c
crypto/cmp/cmp_err.c
crypto/cmp/cmp_local.h
crypto/err/err.c
crypto/err/err_all.c
crypto/err/openssl.ec
crypto/err/openssl.txt
crypto/http/build.info [new file with mode: 0644]
crypto/http/http_client.c [new file with mode: 0644]
crypto/http/http_err.c [new file with mode: 0644]
crypto/http/http_lib.c [new file with mode: 0644]
crypto/http/http_local.h [new file with mode: 0644]
crypto/ocsp/build.info
crypto/ocsp/ocsp_err.c
crypto/ocsp/ocsp_ht.c [deleted file]
crypto/ocsp/ocsp_http.c [new file with mode: 0644]
crypto/ocsp/ocsp_lib.c
crypto/x509/x_all.c
doc/man3/OCSP_sendreq_new.pod
doc/man3/OSSL_CMP_CTX_new.pod
doc/man3/OSSL_HTTP_transfer.pod [new file with mode: 0644]
doc/man3/X509_load_http.pod [new file with mode: 0644]
include/openssl/cmp.h
include/openssl/cmperr.h
include/openssl/err.h
include/openssl/http.h [new file with mode: 0644]
include/openssl/httperr.h [new file with mode: 0644]
include/openssl/ocsp.h
include/openssl/ocsperr.h
include/openssl/types.h
include/openssl/x509.h
test/build.info
test/cmp_ctx_test.c
test/http_test.c [new file with mode: 0644]
test/recipes/80-test_http.t [new file with mode: 0644]
util/err-to-raise
util/libcrypto.num
util/missingcrypto.txt
util/other.syms