mirror of
https://github.com/curl/curl.git
synced 2026-08-26 06:13:35 +03:00
url: proxy ssl connection reuse fix
- tunnel https proxy used for http: transfers does no check if proxy-ssl configuration matches - test cases added, test_10_12 fails on 8.4.0 Closes #12255
This commit is contained in:
parent
7e828fe503
commit
3e6254f819
3 changed files with 120 additions and 12 deletions
20
lib/url.c
20
lib/url.c
|
|
@ -1203,17 +1203,19 @@ ConnectionExists(struct Curl_easy *data,
|
|||
continue;
|
||||
|
||||
if(IS_HTTPS_PROXY(needle->http_proxy.proxytype)) {
|
||||
/* use https proxy */
|
||||
if(needle->http_proxy.proxytype !=
|
||||
check->http_proxy.proxytype)
|
||||
/* https proxies come in different types, http/1.1, h2, ... */
|
||||
if(needle->http_proxy.proxytype != check->http_proxy.proxytype)
|
||||
continue;
|
||||
/* match SSL config to proxy */
|
||||
if(!Curl_ssl_conn_config_match(data, check, TRUE)) {
|
||||
DEBUGF(infof(data,
|
||||
"Connection #%" CURL_FORMAT_CURL_OFF_T
|
||||
" has different SSL proxy parameters, can't reuse",
|
||||
check->connection_id));
|
||||
continue;
|
||||
else if(needle->handler->flags&PROTOPT_SSL) {
|
||||
/* use double layer ssl */
|
||||
if(!Curl_ssl_conn_config_match(data, check, TRUE))
|
||||
continue;
|
||||
}
|
||||
else if(!Curl_ssl_conn_config_match(data, check, FALSE))
|
||||
continue;
|
||||
/* the SSL config to the server, which may apply here is checked
|
||||
* further below */
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue