router

package
v0.3.3 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2022 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const BUFFER_SIZE = 1 << 16
View Source
const MTU int = 1400 // TUN interface, so only plain IP packet, no ethernet header + mtu is set to 1300

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	Init() error
	P2PHost() libp2pHost.Host
	IPv4() string
	SetIPv4(ipv4 string)
	IPv6() string
	SetIPv6(ipv6 string)
	IP4AddrAdd(ipv4 string) error
	IP4AddrDel(ipv4 string) error
	IP6AddrAdd(ipv6 string) error
	IP6AddrDel(ipv6 string) error
	GetLinkStatusConnections() int32
	UpdateRoutingTable(newRT *routing.RoutingTable)
	RtrQueue() chan struct{}
	Disconnect()
}

func New

func New(externalIPv4, vrfID string, port int, isRelay, localForwarding bool, rtImported, rtExported []string) Interface

Jump to

Keyboard shortcuts

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