NewSSHTransport returns an http.Transport which has Dial() which ensures a tunnel is open and then calls ssh.Client.Dial() on the open client to create a tunneled connection
It would be nice not to have to rewrite RoundTrip to allow additional proxy schemes.
I think that this could be solved by checking if either Request Scheme or Proxy Scheme use a different transport and then delegating the rest of the request to the scheme's Transport.
The text was updated successfully, but these errors were encountered:
bradfitz
changed the title
net/http/#Transport does not support proxy schemes added with RegisterProtocol
net/http: Transport does not support proxy schemes added with RegisterProtocol
Nov 27, 2018
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
I checked https://golang.org/src/net/http/transport.go?s=3628:10127#L93 using godoc and it has no handling for Proxies with schemes other than http(s)/socks5, so yes.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
NewSSHTransport
returns anhttp.Transport
which hasDial()
which ensures a tunnel is open and then callsssh.Client.Dial()
on the open client to create a tunneled connectionWhat did you expect to see?
sshTransport Dial to be used for the proxy
What did you see instead?
DefaultTransport Dial was used for the proxy.
It would be nice not to have to rewrite RoundTrip to allow additional proxy schemes.
I think that this could be solved by checking if either Request Scheme or Proxy Scheme use a different transport and then delegating the rest of the request to the scheme's Transport.
The text was updated successfully, but these errors were encountered: