From: Fabian Keil Date: Tue, 3 Mar 2020 11:17:45 +0000 (+0100) Subject: process_encrypted_request(): Add more log messages in case of errors X-Git-Tag: v_3_0_29~442 X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=commitdiff_plain;h=9ca4d4015e89dcbe69c79bb60bc81ad9dc1b0b98;hp=37e87f7b7dbce1ebf3cddd690ce2696b2d0375f6 process_encrypted_request(): Add more log messages in case of errors Sponsored by: Robert Klemme --- diff --git a/jcc.c b/jcc.c index 2000667a..46ff1a28 100644 --- a/jcc.c +++ b/jcc.c @@ -2244,6 +2244,8 @@ static jb_err process_encrypted_request(struct client_state *csp) if (err != JB_ERR_OK) { /* XXX: Also used for JB_ERR_MEMORY */ + log_error(LOG_LEVEL_ERROR, "Failed to receive encrypted request: %s", + jb_err_to_string(err)); ssl_send_data(&(csp->mbedtls_client_attr.ssl), (const unsigned char *)CHEADER, strlen(CHEADER)); return err; @@ -2253,6 +2255,7 @@ static jb_err process_encrypted_request(struct client_state *csp) request_line = get_header(csp->client_iob); if (request_line == NULL) { + log_error(LOG_LEVEL_ERROR, "Failed to get the encrypted request line"); ssl_send_data(&(csp->mbedtls_client_attr.ssl), (const unsigned char *)CHEADER, strlen(CHEADER)); return JB_ERR_PARSE; @@ -2316,6 +2319,8 @@ static jb_err process_encrypted_request(struct client_state *csp) * Our attempts to get the request destination * elsewhere failed. */ + log_error(LOG_LEVEL_ERROR, + "Failed to get the encrypted request destination"); ssl_send_data(&(csp->mbedtls_client_attr.ssl), (const unsigned char *)CHEADER, strlen(CHEADER)); return JB_ERR_PARSE;