You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(ProxyAgent): match Curl behavior in HTTP->HTTP Proxy connections
By default, Curl does not send a CONNECT request to a non-secure
Proxy with a non-secure endpoint. This can be overridden using the
--proxytunnel or -p parameter.
This change modifies ProxyAgent's constructor to accept a
`tunnelProxy` option, sends a CONNECT if either `tunnelProxy` is
true, or either the Proxy or endpoint use a non-'http:' protocol.
Disabling tunneling for HTTP->HTTP by default would be a breaking
change, so currently, the tunneling behavior requires an opt-out.
This may change depending on feedback during code review.
This adds a new test case which explicitly disables tunneling for an
HTTP->HTTP connection, and asserts that no CONNECT message is sent to
the server or proxy, and that the expected HTTP request is sent to
the proxy.
Closes#4083
0 commit comments