From: Kale Blankenship Date: Thu, 15 Jun 2017 02:44:20 +0000 (-0700) Subject: net/http: document SOCKS5 proxy support X-Git-Tag: go1.9beta2~75 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=75ab6134fcea003803e25c9bad7f092be3eeb5c3;p=gostls13.git net/http: document SOCKS5 proxy support Fixes #20618 Change-Id: I90712bd76d9d47f29221bc298c69737ebee25c12 Reviewed-on: https://go-review.googlesource.com/45814 Reviewed-by: Brad Fitzpatrick --- diff --git a/src/net/http/transport.go b/src/net/http/transport.go index 9dedc22272..6a89392a99 100644 --- a/src/net/http/transport.go +++ b/src/net/http/transport.go @@ -89,6 +89,11 @@ type Transport struct { // Proxy specifies a function to return a proxy for a given // Request. If the function returns a non-nil error, the // request is aborted with the provided error. + // + // The proxy type is determined by the URL scheme. "http" + // and "socks5" are supported. If the scheme is empty, + // "http" is assumed. + // // If Proxy is nil or returns a nil *URL, no proxy is used. Proxy func(*Request) (*url.URL, error)