Documentation ¶
Index ¶
- Constants
- func NewSocks5Dialer(s string, dialer proxy.Dialer) (proxy.Dialer, error)
- func NewSocks5Server(s string, dialer proxy.Dialer) (proxy.Server, error)
- type PktConn
- type SOCKS5
- func (s *SOCKS5) Addr() string
- func (s *SOCKS5) Dial(network, addr string) (net.Conn, error)
- func (s *SOCKS5) DialUDP(network, addr string) (pc net.PacketConn, writeTo net.Addr, err error)
- func (s *SOCKS5) ListenAndServe()
- func (s *SOCKS5) ListenAndServeTCP()
- func (s *SOCKS5) ListenAndServeUDP()
- func (s *SOCKS5) NextDialer(dstAddr string) proxy.Dialer
- func (s *SOCKS5) ServeTCP(c net.Conn)
Constants ¶
View Source
const Version = 5
Version is socks5 version number
Variables ¶
This section is empty.
Functions ¶
func NewSocks5Dialer ¶
NewSocks5Dialer returns a socks5 proxy dialer.
Types ¶
type PktConn ¶
type PktConn struct { net.PacketConn // contains filtered or unexported fields }
PktConn .
func NewPktConn ¶
func NewPktConn(c net.PacketConn, writeAddr net.Addr, tgtAddr socks.Addr, tgtHeader bool, ctrlConn net.Conn) *PktConn
NewPktConn returns a PktConn
type SOCKS5 ¶
type SOCKS5 struct {
// contains filtered or unexported fields
}
SOCKS5 struct
func NewSOCKS5 ¶
NewSOCKS5 returns a Proxy that makes SOCKS v5 connections to the given address with an optional username and password. See RFC 1928.
func (*SOCKS5) ListenAndServe ¶
func (s *SOCKS5) ListenAndServe()
ListenAndServe serves socks5 requests.
func (*SOCKS5) ListenAndServeUDP ¶
func (s *SOCKS5) ListenAndServeUDP()
ListenAndServeUDP serves udp requests.
func (*SOCKS5) NextDialer ¶
NextDialer returns the next dialer
Click to show internal directories.
Click to hide internal directories.