MCPcopy
hub / github.com/gorilla/websocket / proxy_SOCKS5

Function proxy_SOCKS5

x_net_proxy.go:275–287  ·  view source on GitHub ↗

SOCKS5 returns a Dialer that makes SOCKSv5 connections to the given address with an optional username and password. See RFC 1928 and RFC 1929.

(network, addr string, auth *proxy_Auth, forward proxy_Dialer)

Source from the content-addressed store, hash-verified

273// SOCKS5 returns a Dialer that makes SOCKSv5 connections to the given address
274// with an optional username and password. See RFC 1928 and RFC 1929.
275func proxy_SOCKS5(network, addr string, auth *proxy_Auth, forward proxy_Dialer) (proxy_Dialer, error) {
276 s := &proxy_socks5{
277 network: network,
278 addr: addr,
279 forward: forward,
280 }
281 if auth != nil {
282 s.user = auth.User
283 s.password = auth.Password
284 }
285
286 return s, nil
287}
288
289type proxy_socks5 struct {
290 user, password string

Callers 1

proxy_FromURLFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected