diff options
author | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2022-05-28 18:44:02 +0200 |
---|---|---|
committer | Dr. David von Oheimb <dev@ddvo.net> | 2022-09-07 23:04:25 +0200 |
commit | 8aff29f020752c96cc2ab7d111d9c33aaf55c671 (patch) | |
tree | 147cf3269d3859001138a53d99a79473d9ff5db4 /apps/ocsp.c | |
parent | 5d0a327020d238949ffbcff56e1c32aa4a436f52 (diff) |
APPS HTTP server: trace requests and responses when enabled
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: David von Oheimb <david.von.oheimb@siemens.com>
(Merged from https://github.com/openssl/openssl/pull/18434)
Diffstat (limited to 'apps/ocsp.c')
-rw-r--r-- | apps/ocsp.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/apps/ocsp.c b/apps/ocsp.c index b1a86dcf5b..297b10c861 100644 --- a/apps/ocsp.c +++ b/apps/ocsp.c @@ -633,14 +633,15 @@ int ocsp_main(int argc, char **argv) } #ifdef HTTP_DAEMON - if (multi && acbio != NULL) + if (multi != 0 && acbio != NULL) spawn_loop(prog); if (acbio != NULL && req_timeout > 0) signal(SIGALRM, socket_timeout); #endif if (acbio != NULL) - log_message(prog, LOG_INFO, "waiting for OCSP client connections..."); + trace_log_message(-1, prog, + LOG_INFO, "waiting for OCSP client connections..."); redo_accept: @@ -654,8 +655,9 @@ redo_accept: rdb = newrdb; } else { free_index(newrdb); - log_message(prog, LOG_ERR, "error reloading updated index: %s", - ridx_filename); + trace_log_message(-1, prog, + LOG_ERR, "error reloading updated index: %s", + ridx_filename); } } #endif @@ -1217,7 +1219,7 @@ static int do_responder(OCSP_REQUEST **preq, BIO **pcbio, BIO *acbio, static int send_ocsp_response(BIO *cbio, const OCSP_RESPONSE *resp) { #ifndef OPENSSL_NO_SOCK - return http_server_send_asn1_resp(cbio, + return http_server_send_asn1_resp(prog, cbio, 0 /* no keep-alive */, "application/ocsp-response", ASN1_ITEM_rptr(OCSP_RESPONSE), |