socks5

package
v0.0.0-...-69a5761 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TCPProxy

type TCPProxy struct {
	Session *smux.Session
	Lock    sync.Mutex
}

TCPProxy The tcp proxy struct

func (*TCPProxy) Proxy

func (t *TCPProxy) Proxy(tcpConn net.Conn, req []byte)

Proxy is a function to proxy data

type TCPServer

type TCPServer struct {
	TCPProxy *TCPProxy
	UDPProxy *UDPProxy
	UDPConn  *net.UDPConn
	Listener net.Listener
}

func (*TCPServer) Start

func (t *TCPServer) Start()

type UDPProxy

type UDPProxy struct {
}

The UDPProxy struct

func (*UDPProxy) Proxy

func (u *UDPProxy) Proxy(tcpConn net.Conn, udpConn *net.UDPConn)

Proxy handles the udp connection

type UDPServer

type UDPServer struct {
	TCPProxy *TCPProxy
	UDPConn  *net.UDPConn

	Session *smux.Session
	Lock    sync.Mutex
	// contains filtered or unexported fields
}

func (*UDPServer) Start

func (u *UDPServer) Start() *net.UDPConn

Start the UDP server

Jump to

Keyboard shortcuts

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