Documentation
¶
Index ¶
- Constants
- func BPF() []byte
- func Load(file string) (map[uint16]net.IPNet, error)
- func VlanInterface(prefix net.IPNet) (ret iface, _ bool)
- func VlanInterfaces(in map[uint16]net.IPNet) map[uint16]iface
- type Client
- func (b *Client) CreateDestination(s Service, d Destination) error
- func (b *Client) CreateService(s Service) error
- func (b *Client) Destinations(s Service) ([]DestinationExtended, error)
- func (b *Client) NATAddr(vip, rip IP4) (r IP4, _ bool)
- func (b *Client) NATAddress(vip, rip netip.Addr) (r netip.Addr, _ bool)
- func (b *Client) RemoveDestination(s Service, d Destination) error
- func (b *Client) RemoveService(s Service) error
- func (b *Client) Service(s Service) (se ServiceExtended, e error)
- func (b *Client) Services() ([]ServiceExtended, error)
- func (b *Client) Start(address string, nic string) error
- func (b *Client) UpdateDestination(s Service, d Destination) error
- func (b *Client) VLANs(vlans map[uint16]net.IPNet)
- type Destination
- type DestinationExtended
- type ICMPs
- type IP4
- type MAC
- type Maps
- type Prefix
- type Protocol
- type Service
- type ServiceExtended
- type Stats
- type Target
Constants ¶
View Source
const ( A = false B = true )
View Source
const ( TCP protocol = 0x06 UDP protocol = 0x11 )
View Source
const NAMESPACE = "vc5"
View Source
const PREFIXES = 1048576
Variables ¶
This section is empty.
Functions ¶
func VlanInterface ¶
Types ¶
type Client ¶
type Client struct { Interfaces []string // contains filtered or unexported fields }
func (*Client) CreateDestination ¶
func (b *Client) CreateDestination(s Service, d Destination) error
func (*Client) CreateService ¶
func (*Client) Destinations ¶
func (b *Client) Destinations(s Service) ([]DestinationExtended, error)
func (*Client) NATAddress ¶ added in v0.0.9
func (*Client) RemoveDestination ¶
func (b *Client) RemoveDestination(s Service, d Destination) error
func (*Client) RemoveService ¶
func (*Client) Service ¶ added in v0.0.15
func (b *Client) Service(s Service) (se ServiceExtended, e error)
func (*Client) Services ¶
func (b *Client) Services() ([]ServiceExtended, error)
func (*Client) UpdateDestination ¶
func (b *Client) UpdateDestination(s Service, d Destination) error
type Destination ¶
type DestinationExtended ¶
type DestinationExtended struct { Destination Destination MAC MAC Stats Stats }
type Service ¶
type ServiceExtended ¶
Click to show internal directories.
Click to hide internal directories.