inbound

package
v1.53.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHTTP

func NewHTTP(target socks5.Addr, source net.Addr, originTarget net.Addr, conn net.Conn) *context.ConnContext

NewHTTP receive normal http request and return HTTPContext

func NewHTTPS

func NewHTTPS(request *http.Request, conn net.Conn) *context.ConnContext

NewHTTPS receive CONNECT request and return ConnContext

func NewMitm

func NewMitm(target socks5.Addr, source net.Addr, originTarget net.Addr, userAgent string, specialProxy string, conn net.Conn) *context.ConnContext

NewMitm receive mitm request and return MitmContext

func NewSocket

func NewSocket(target socks5.Addr, conn net.Conn, source C.Type) *context.ConnContext

NewSocket receive TCP inbound and return ConnContext

func NewSocketBy

func NewSocketBy(conn net.Conn, src, dst netip.AddrPort, tp C.Type) *context.ConnContext

NewSocketBy receive TCP inbound and return ConnContext

Types

type PacketAdapter

type PacketAdapter struct {
	C.UDPPacket
	// contains filtered or unexported fields
}

PacketAdapter is a UDP Packet adapter for socks/redir/tun

func NewPacket

func NewPacket(target socks5.Addr, originTarget net.Addr, packet C.UDPPacket, source C.Type) *PacketAdapter

NewPacket is PacketAdapter generator

func NewPacketBy

func NewPacketBy(packet C.UDPPacket, src, dst netip.AddrPort, tp C.Type) *PacketAdapter

NewPacketBy is PacketAdapter generator

func (*PacketAdapter) Metadata

func (s *PacketAdapter) Metadata() *C.Metadata

Metadata returns destination metadata

Jump to

Keyboard shortcuts

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