sed_https(): Unset CSP_FLAG_CLIENT_HEADER_PARSING_DONE
[privoxy.git] / ssl.c
diff --git a/ssl.c b/ssl.c
index 8d9a55a..732cd25 100644 (file)
--- a/ssl.c
+++ b/ssl.c
@@ -820,8 +820,8 @@ extern int create_server_ssl_connection(struct client_state *csp)
 
             /* Log the reason without the trailing new line */
             log_error(LOG_LEVEL_ERROR,
-               "The X509 certificate verification failed: %N",
-               strlen(reason)-1, reason);
+               "X509 certificate verification for %s failed: %N",
+               csp->http->hostport, strlen(reason)-1, reason);
             ret = -1;
          }
          else
@@ -1689,7 +1689,7 @@ extern void ssl_send_certificate_error(struct client_state *csp)
       "HTTP/1.1 200 OK\r\n"
       "Content-Type: text/html\r\n"
       "Connection: close\r\n\r\n"
-      "<html><body><h1>Invalid server certificate</h1><p>Reason: ";
+      "<html><body><h1>Server certificate verification failed</h1><p>Reason: ";
    const char message_end[] = "</body></html>\r\n\r\n";
    char reason[INVALID_CERT_INFO_BUF_SIZE];
    memset(reason, 0, sizeof(reason));
@@ -1764,11 +1764,6 @@ extern void ssl_send_certificate_error(struct client_state *csp)
     */
    ssl_send_data(&(csp->mbedtls_client_attr.ssl),
       (const unsigned char *)message, strlen(message));
-   /*
-    * Waiting before closing connection. Some browsers don't show received
-    * message if there isn't this delay.
-    */
-   sleep(1);
 
    free_certificate_chain(csp);
 }