validation

package
v0.0.0-...-bf9fd61 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: Apache-2.0 Imports: 16 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetOriginalDestination

func GetOriginalDestination(conn net.Conn) (daddr net.IP, dport uint16, err error)

Recover the original address from redirect socket. Supposed to work for tcp over ipv4 and ipv6.

Types

type Client

type Client struct {
	Config *Config
}

func (*Client) Run

func (c *Client) Run() error

type Config

type Config struct {
	ServerListenAddress []string
	ServerOriginalPort  uint16
	ServerOriginalIP    netip.Addr
	ServerReadyBarrier  chan ReturnCode
	ProbeTimeout        time.Duration
}

type ReturnCode

type ReturnCode int
const (
	DONE ReturnCode = iota
)

type Service

type Service struct {
	Config *Config
}

func (*Service) Run

func (s *Service) Run() error

type Validator

type Validator struct {
	Config *Config
}

func NewValidator

func NewValidator(config *config.Config) *Validator

func (*Validator) Run

func (validator *Validator) Run() error

Jump to

Keyboard shortcuts

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