Documentation
¶
Index ¶
- Constants
- func DelRoute(linkIndex int, ip *net.IPNet) error
- func GetIPNets(address net.IP, subnet *net.IPNet) (*net.IPNet, *net.IPNet)
- func LinkIndexFromIPNet(address *net.IPNet) (int, error)
- func NewConfig(confBytes []byte) (*cni.Config, error)
- func SelectAddress(cidr string, xf, xl int) (*net.IPNet, error)
Constants ¶
View Source
const ( DefaultRequestedAddressSleepTime = 100 DefaultPropagationTimeout = 100 DefaultRouteProtocol = 192 )
- DefaultRequestedAddressSleepTime is the default amount of time (ms) we wait between tries to select a requested address
- DefaultPropagationTimeout is the amount of time (ms) we wait for the possibility that another host has selected the same address
* DefaultRouteProtocol is the default protocol number for our installed routes
Variables ¶
This section is empty.
Functions ¶
func GetIPNets ¶
GetIPNets takes an IP and a subnet and returns the IPNet representing the IP in the subnet, as well as an IPNet representing the "host only" cidr in other words a /32 in IPv4 or a /128 in IPv6
func LinkIndexFromIPNet ¶
LinkIndexFromIPNet gets the link index of the first interface which is on the same subnet as the parameter
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.