socks5

package
v0.14.2 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2024 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPResponseWriter

type HTTPResponseWriter struct {
	net.Conn
	// contains filtered or unexported fields
}

func (*HTTPResponseWriter) Header

func (w *HTTPResponseWriter) Header() http.Header

func (*HTTPResponseWriter) Write

func (w *HTTPResponseWriter) Write(data []byte) (int, error)

func (*HTTPResponseWriter) WriteHeader

func (w *HTTPResponseWriter) WriteHeader(statusCode int)

type Handler

type Handler func(w http.ResponseWriter, r *http.Request)

type HttpServer added in v0.13.0

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

func (*HttpServer) Route added in v0.13.0

func (s *HttpServer) Route(path string, handler Handler)

type Options

type Options struct {
	Listen         string
	AdvertiseIP    string
	AdvertisePort  uint16
	TCPDialContext func(ctx context.Context, addr string) (
		dialerName string, conn net.Conn, err error)
	UDPDialContext func(ctx context.Context, addr string) (
		dialerName string, conn net.Conn, err error)
	TrafficEventConsumer func(e *spec.TrafficEvent)
}

type Socks5Server

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

func NewSocks5Server

func NewSocks5Server(opts Options) (s *Socks5Server, err error)

func (*Socks5Server) HttpServer added in v0.13.0

func (s *Socks5Server) HttpServer() *HttpServer

func (*Socks5Server) Run

func (s *Socks5Server) Run() error

Jump to

Keyboard shortcuts

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