gvisor

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2024 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const MTU uint32 = 1400
View Source
const NICID tcpip.NICID = 1

Variables

This section is empty.

Functions

This section is empty.

Types

type Endpoint

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

func (*Endpoint) ARPHardwareType

func (ep *Endpoint) ARPHardwareType() header.ARPHardwareType

func (*Endpoint) AddHeader

func (ep *Endpoint) AddHeader(stack.PacketBufferPtr)

func (*Endpoint) Attach

func (ep *Endpoint) Attach(dispatcher stack.NetworkDispatcher)

func (*Endpoint) Capabilities

func (ep *Endpoint) Capabilities() stack.LinkEndpointCapabilities

func (*Endpoint) IsAttached

func (ep *Endpoint) IsAttached() bool

func (*Endpoint) LinkAddress

func (ep *Endpoint) LinkAddress() tcpip.LinkAddress

func (*Endpoint) MTU

func (ep *Endpoint) MTU() uint32

func (*Endpoint) MaxHeaderLength

func (ep *Endpoint) MaxHeaderLength() uint16

func (*Endpoint) ParseHeader

func (ep *Endpoint) ParseHeader(stack.PacketBufferPtr) bool

func (*Endpoint) Wait

func (ep *Endpoint) Wait()

func (*Endpoint) WritePackets

func (ep *Endpoint) WritePackets(list stack.PacketBufferList) (int, tcpip.Error)

WritePackets is called when get packets from gVisor stack. Then it sends them to VPN server

type Stack

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

func NewStack

func NewStack(easyConnectClient *client.EasyConnectClient) (*Stack, error)

func (*Stack) DialTCP

func (s *Stack) DialTCP(addr *net.TCPAddr) (net.Conn, error)

func (*Stack) DialUDP

func (s *Stack) DialUDP(addr *net.UDPAddr) (net.Conn, error)

func (*Stack) Run

func (s *Stack) Run()

func (*Stack) SetupResolve added in v0.6.0

func (s *Stack) SetupResolve(r zcdns.LocalServer)

Jump to

Keyboard shortcuts

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