overlay

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: May 8, 2024 License: MIT Imports: 20 Imported by: 1

Documentation

Index

Constants

View Source
const DefaultMTU = 1300

Variables

This section is empty.

Functions

This section is empty.

Types

type Device

type Device interface {
	io.ReadWriteCloser
	Activate() error
	Cidr() *net.IPNet
	Name() string
	RouteFor(iputil.VpnIp) iputil.VpnIp
	NewMultiQueueReader() (io.ReadWriteCloser, error)
}

func NewDeviceFromConfig

func NewDeviceFromConfig(c *config.C, l *logrus.Logger, tunCidr *net.IPNet, routines int) (Device, error)

func NewUserDevice added in v1.8.0

func NewUserDevice(tunCidr *net.IPNet) (Device, error)

func NewUserDeviceFromConfig added in v1.8.0

func NewUserDeviceFromConfig(c *config.C, l *logrus.Logger, tunCidr *net.IPNet, routines int) (Device, error)

type DeviceFactory added in v1.8.0

type DeviceFactory func(c *config.C, l *logrus.Logger, tunCidr *net.IPNet, routines int) (Device, error)

TODO: We may be able to remove routines

func NewFdDeviceFromConfig added in v1.8.0

func NewFdDeviceFromConfig(fd *int) DeviceFactory

type Route

type Route struct {
	MTU     int
	Metric  int
	Cidr    *net.IPNet
	Via     *iputil.VpnIp
	Install bool
}

func (Route) Equal added in v1.9.0

func (r Route) Equal(t Route) bool

Equal determines if a route that could be installed in the system route table is equal to another Via is ignored since that is only consumed within nebula itself

func (Route) String added in v1.9.0

func (r Route) String() string

type UserDevice added in v1.8.0

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

func (*UserDevice) Activate added in v1.8.0

func (d *UserDevice) Activate() error

func (*UserDevice) Cidr added in v1.8.0

func (d *UserDevice) Cidr() *net.IPNet

func (*UserDevice) Close added in v1.8.0

func (d *UserDevice) Close() error

func (*UserDevice) Name added in v1.8.0

func (d *UserDevice) Name() string

func (*UserDevice) NewMultiQueueReader added in v1.8.0

func (d *UserDevice) NewMultiQueueReader() (io.ReadWriteCloser, error)

func (*UserDevice) Pipe added in v1.8.0

func (d *UserDevice) Pipe() (*io.PipeReader, *io.PipeWriter)

func (*UserDevice) Read added in v1.8.0

func (d *UserDevice) Read(p []byte) (n int, err error)

func (*UserDevice) RouteFor added in v1.8.0

func (d *UserDevice) RouteFor(ip iputil.VpnIp) iputil.VpnIp

func (*UserDevice) Write added in v1.8.0

func (d *UserDevice) Write(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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