anyproxy

package module
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2020 License: MIT Imports: 12 Imported by: 4

README

anyproxy

Proxy server supporting http/socks4/socks5 on port

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNetClosing = errors.New("use of closed network connection")

Functions

This section is empty.

Types

type AnyProxy

type AnyProxy struct {
	Socks4 socks4.Server
	Socks5 socks5.Server
	Http   http.Server
	Mux    *shunt.Mux
}

func NewAnyProxy

func NewAnyProxy(dial Dialer, logger *log.Logger) *AnyProxy

func (*AnyProxy) ListenAndServe

func (s *AnyProxy) ListenAndServe(network, address string) error

func (*AnyProxy) ServeConn

func (s *AnyProxy) ServeConn(conn net.Conn)

ServeConn is used to serve a single connection.

type Dialer

type Dialer interface {
	DialContext(ctx context.Context, network, address string) (net.Conn, error)
}

Directories

Path Synopsis
cmd
anyproxy command

Jump to

Keyboard shortcuts

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