socks5

package
v0.0.0-...-58a2b35 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Direct = direct{}

Direct is a direct proxy which implements Dialer interface: one that makes connections directly.

Functions

This section is empty.

Types

type Dialer

type Dialer interface {
	// Dial connects to the given address via the proxy.
	Dial(network, address string) (net.Conn, error)
}

A Dialer is a means to establish a connection.

type Socks5Server

type Socks5Server struct {
	// contains filtered or unexported fields
}

Socks5Server implements Socks5 Proxy Protocol(RFC 1928), just support CONNECT command.

func NewSocks5Server

func NewSocks5Server(forward Dialer) (*Socks5Server, error)

NewSocks5Server return a new Socks5Server

func (*Socks5Server) Serve

func (s *Socks5Server) Serve(listener net.Listener) error

Serve with net.Listener for new incoming clients.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL