X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=blobdiff_plain;f=jcc.c;h=20337fb8d971d72e07e018e38d6ecc5394a50a9e;hp=132618b8b950eba3f351278cc5533154bd20a381;hb=6e0aa492fff31c5391048452d8f19af82eb77b0f;hpb=704917e90c0566ef48bf1c4ebaa1407e5cbd0cf7 diff --git a/jcc.c b/jcc.c index 132618b8..20337fb8 100644 --- a/jcc.c +++ b/jcc.c @@ -6,7 +6,7 @@ * the main connection-handling function. * * Copyright : Written by and Copyright (C) 2001-2019 the - * Privoxy team. http://www.privoxy.org/ + * Privoxy team. https://www.privoxy.org/ * * Based on the Internet Junkbuster originally written * by and Copyright (C) 1997 Anonymous Coders and @@ -194,11 +194,11 @@ privoxy_mutex_t log_init_mutex; privoxy_mutex_t connection_reuse_mutex; #ifdef LIMIT_MUTEX_NUMBER - privoxy_mutex_t certificates_mutexes[32]; +privoxy_mutex_t certificates_mutexes[32]; #else - privoxy_mutex_t certificates_mutexes[65536]; +privoxy_mutex_t certificates_mutexes[65536]; #endif /* LIMIT_MUTEX_NUMBER */ - privoxy_mutex_t rng_mutex; +privoxy_mutex_t rng_mutex; #ifdef FEATURE_EXTERNAL_FILTERS privoxy_mutex_t external_filter_mutex; @@ -3611,9 +3611,16 @@ static void chat(struct client_state *csp) build_request_line(csp, fwd, &csp->headers->first->str); /* - * We have a request. Check if one of the crunchers wants it. + * We have a request. Check if one of the crunchers wants it + * unless the client wants to use TLS/SSL in which case we + * haven't setup the TLS context yet and will send the crunch + * response later. */ - if (crunch_response_triggered(csp, crunchers_all)) + if ( +#ifdef FEATURE_HTTPS_FILTERING + !client_use_ssl(csp) && +#endif + crunch_response_triggered(csp, crunchers_all)) { /* * Yes. The client got the crunch response and we're done here.