socks

package
v1.23.1 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2016 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AuthTypeNoAuth   = byte(0)
	AuthTypePassword = byte(1)
)

Variables

View Source
var (
	ErrUnsupportedSocksCommand = errors.New("Unsupported socks command.")
	ErrUnsupportedAuthMethod   = errors.New("Unsupported auth method.")
)

Functions

This section is empty.

Types

type Account added in v1.1.0

type Account struct {
	Username string `json:"user"`
	Password string `json:"pass"`
}

func (*Account) Equals added in v1.1.0

func (this *Account) Equals(another protocol.Account) bool

type ClientConfig added in v1.1.0

type ClientConfig struct {
	Servers []*protocol.ServerSpec
}

type Config added in v1.1.2

type Config struct {
	AuthType   byte
	Accounts   map[string]string
	Address    v2net.Address
	UDPEnabled bool
	Timeout    int
}

func (*Config) HasAccount added in v1.1.2

func (this *Config) HasAccount(username, password string) bool

type Server added in v1.1.0

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

Server is a SOCKS 5 proxy server

func NewServer added in v1.1.0

func NewServer(config *Config, space app.Space, meta *proxy.InboundHandlerMeta) *Server

NewServer creates a new Server object.

func (*Server) Close added in v1.12.1

func (this *Server) Close()

Close implements InboundHandler.Close().

func (*Server) Port added in v1.12.1

func (this *Server) Port() v2net.Port

Port implements InboundHandler.Port().

func (*Server) Start added in v1.17.1

func (this *Server) Start() error

Listen implements InboundHandler.Listen().

type ServerFactory added in v1.17.1

type ServerFactory struct{}

func (*ServerFactory) Create added in v1.17.1

func (this *ServerFactory) Create(space app.Space, rawConfig interface{}, meta *proxy.InboundHandlerMeta) (proxy.InboundHandler, error)

func (*ServerFactory) StreamCapability added in v1.17.1

func (this *ServerFactory) StreamCapability() internet.StreamConnectionType

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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