Closed barjin closed 3 months ago
Huh, so the description of this PR mentions the existence of "no-CONNECT
" proxies. I'm not sure whether there is an easy way of determining whether a proxy supports the CONNECT
method (an easy way other than a preflight CONNECT
request).
As discussed w/ @B4nan, we'll go through with this - there is no repro to be found for the "no-CONNECT" proxies - worst case, we can always revert (and we'll have the actual repro by then :))
Previously, HTTP request (
http://example.com/resource
) over HTTPS proxy (https://proxy.com
) was sent as:https://proxy.com/example.com/resource
.After a discussion with @jirimoravcik , we figured that the "pathname" proxies are a marginal thing (
CONNECT
is more popular nowadays).This PR fixes that -
got-scraping
now does:HTTPS CONNECT ->
https://proxy.com/
-> HTTP GEThttp://example.com/resource
.Yet, there is still this comment:
// Upstream proxies hang up connections on CONNECT + unsecure HTTP
maybe @szmarczak knows what that was supposed to mean? 😅 seems dangerously close to what we want to do now.Fixes #126