Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type HttpTunnel ¶
type HttpTunnel struct {
// contains filtered or unexported fields
}
HttpTunnel represents a configured HTTP Connect Tunnel dialer.
type Opt ¶
type Opt func(*HttpTunnel)
func WithDialer ¶
WithDialer allows the customization of the underlying net.Dialer used for establishing TCP connections to the proxy.
func WithProxyAuth ¶
func WithProxyAuth(auth ProxyAuthorization) Opt
WithProxyAuth allows you to add ProxyAuthorization to calls.
type ProxyAuthorization ¶
type ProxyAuthorization interface {
// Type represents what kind of Authorization, e.g. "Bearer", "Token", "Digest".
Type() string
// Initial allows you to specify an a-priori "Proxy-Authenticate" response header, attached to first request,
// so you don't need to wait for an additional challenge. If empty string is returned, "Proxy-Authenticate"
// header is added.
InitialResponse() string
// ChallengeResponse returns the content of the "Proxy-Authenticate" response header, that has been chose as
// response to "Proxy-Authorization" request header challenge.
ChallengeResponse(challenge string) string
}
ProxyAuthorization allows for plugging in arbitrary implementations of the "Proxy-Authorization" handler.
Click to show internal directories.
Click to hide internal directories.