kubernetes/vendor/github.com/vishvananda/netlink/route_linux.go

const SCOPE_UNIVERSE

const SCOPE_SITE

const SCOPE_LINK

const SCOPE_HOST

const SCOPE_NOWHERE

func (s Scope) String() string {}

const FLAG_ONLINK

const FLAG_PERVASIVE

var testFlags

func listFlags(flag int) []string {}

func (r *Route) ListFlags() []string {}

func (n *NexthopInfo) ListFlags() []string {}

type MPLSDestination

func (d *MPLSDestination) Family() int {}

func (d *MPLSDestination) Decode(buf []byte) error {}

func (d *MPLSDestination) Encode() ([]byte, error) {}

func (d *MPLSDestination) String() string {}

func (d *MPLSDestination) Equal(x Destination) bool {}

type MPLSEncap

func (e *MPLSEncap) Type() int {}

func (e *MPLSEncap) Decode(buf []byte) error {}

func (e *MPLSEncap) Encode() ([]byte, error) {}

func (e *MPLSEncap) String() string {}

func (e *MPLSEncap) Equal(x Encap) bool {}

type SEG6Encap

func (e *SEG6Encap) Type() int {}

func (e *SEG6Encap) Decode(buf []byte) error {}

func (e *SEG6Encap) Encode() ([]byte, error) {}

func (e *SEG6Encap) String() string {}

func (e *SEG6Encap) Equal(x Encap) bool {}

type SEG6LocalEncap

func (e *SEG6LocalEncap) SetProg(progFd int, progName string) error {}

func (e *SEG6LocalEncap) Type() int {}

func (e *SEG6LocalEncap) Decode(buf []byte) error {}

func (e *SEG6LocalEncap) Encode() ([]byte, error) {}

func (e *SEG6LocalEncap) String() string {}

func (e *SEG6LocalEncap) Equal(x Encap) bool {}

type bpfObj

type BpfEncap

// SetProg adds a bpf function to the route via netlink RTA_ENCAP. The fd must be a bpf
// program loaded with bpf(type=BPF_PROG_TYPE_LWT_*) matching the direction the program should
// be applied to (LWT_BPF_IN, LWT_BPF_OUT, LWT_BPF_XMIT).
func (e *BpfEncap) SetProg(mode, progFd int, progName string) error {}

// SetXmitHeadroom sets the xmit headroom (LWT_BPF_MAX_HEADROOM) via netlink RTA_ENCAP.
// maximum headroom is LWT_BPF_MAX_HEADROOM
func (e *BpfEncap) SetXmitHeadroom(headroom int) error {}

func (e *BpfEncap) Type() int {}

func (e *BpfEncap) Decode(buf []byte) error {}

func (e *BpfEncap) Encode() ([]byte, error) {}

func (e *BpfEncap) String() string {}

func (e *BpfEncap) Equal(x Encap) bool {}

type IP6tnlEncap

func (e *IP6tnlEncap) Type() int {}

func (e *IP6tnlEncap) Decode(buf []byte) error {}

func (e *IP6tnlEncap) Encode() ([]byte, error) {}

func (e *IP6tnlEncap) String() string {}

func (e *IP6tnlEncap) Equal(x Encap) bool {}

type Via

func (v *Via) Equal(x Destination) bool {}

func (v *Via) String() string {}

func (v *Via) Family() int {}

func (v *Via) Encode() ([]byte, error) {}

func (v *Via) Decode(b []byte) error {}

// RouteAdd will add a route to the system.
// Equivalent to: `ip route add $route`
func RouteAdd(route *Route) error {}

// RouteAdd will add a route to the system.
// Equivalent to: `ip route add $route`
func (h *Handle) RouteAdd(route *Route) error {}

// RouteAppend will append a route to the system.
// Equivalent to: `ip route append $route`
func RouteAppend(route *Route) error {}

// RouteAppend will append a route to the system.
// Equivalent to: `ip route append $route`
func (h *Handle) RouteAppend(route *Route) error {}

// RouteAddEcmp will add a route to the system.
func RouteAddEcmp(route *Route) error {}

// RouteAddEcmp will add a route to the system.
func (h *Handle) RouteAddEcmp(route *Route) error {}

// RouteChange will change an existing route in the system.
// Equivalent to: `ip route change $route`
func RouteChange(route *Route) error {}

// RouteChange will change an existing route in the system.
// Equivalent to: `ip route change $route`
func (h *Handle) RouteChange(route *Route) error {}

// RouteReplace will add a route to the system.
// Equivalent to: `ip route replace $route`
func RouteReplace(route *Route) error {}

// RouteReplace will add a route to the system.
// Equivalent to: `ip route replace $route`
func (h *Handle) RouteReplace(route *Route) error {}

// RouteDel will delete a route from the system.
// Equivalent to: `ip route del $route`
func RouteDel(route *Route) error {}

// RouteDel will delete a route from the system.
// Equivalent to: `ip route del $route`
func (h *Handle) RouteDel(route *Route) error {}

func (h *Handle) routeHandle(route *Route, req *nl.NetlinkRequest, msg *nl.RtMsg) ([][]byte, error) {}

func (h *Handle) routeHandleIter(route *Route, req *nl.NetlinkRequest, msg *nl.RtMsg, f func(msg []byte) bool) error {}

func (h *Handle) prepareRouteReq(route *Route, req *nl.NetlinkRequest, msg *nl.RtMsg) error {}

// RouteList gets a list of routes in the system.
// Equivalent to: `ip route show`.
// The list can be filtered by link and ip family.
func RouteList(link Link, family int) ([]Route, error) {}

// RouteList gets a list of routes in the system.
// Equivalent to: `ip route show`.
// The list can be filtered by link and ip family.
func (h *Handle) RouteList(link Link, family int) ([]Route, error) {}

// RouteListFiltered gets a list of routes in the system filtered with specified rules.
// All rules must be defined in RouteFilter struct
func RouteListFiltered(family int, filter *Route, filterMask uint64) ([]Route, error) {}

// RouteListFiltered gets a list of routes in the system filtered with specified rules.
// All rules must be defined in RouteFilter struct
func (h *Handle) RouteListFiltered(family int, filter *Route, filterMask uint64) ([]Route, error) {}

// RouteListFilteredIter passes each route that matches the filter to the given iterator func.  Iteration continues
// until all routes are loaded or the func returns false.
func RouteListFilteredIter(family int, filter *Route, filterMask uint64, f func(Route) (cont bool)) error {}

func (h *Handle) RouteListFilteredIter(family int, filter *Route, filterMask uint64, f func(Route) (cont bool)) error {}

// deserializeRoute decodes a binary netlink message into a Route struct
func deserializeRoute(m []byte) (Route, error) {}

type RouteGetOptions

// RouteGetWithOptions gets a route to a specific destination from the host system.
// Equivalent to: 'ip route get <> vrf <VrfName>'.
func RouteGetWithOptions(destination net.IP, options *RouteGetOptions) ([]Route, error) {}

// RouteGet gets a route to a specific destination from the host system.
// Equivalent to: 'ip route get'.
func RouteGet(destination net.IP) ([]Route, error) {}

// RouteGetWithOptions gets a route to a specific destination from the host system.
// Equivalent to: 'ip route get <> vrf <VrfName>'.
func (h *Handle) RouteGetWithOptions(destination net.IP, options *RouteGetOptions) ([]Route, error) {}

// RouteGet gets a route to a specific destination from the host system.
// Equivalent to: 'ip route get'.
func (h *Handle) RouteGet(destination net.IP) ([]Route, error) {}

// RouteSubscribe takes a chan down which notifications will be sent
// when routes are added or deleted. Close the 'done' chan to stop subscription.
func RouteSubscribe(ch chan<- RouteUpdate, done <-chan struct{}

// RouteSubscribeAt works like RouteSubscribe plus it allows the caller
// to choose the network namespace in which to subscribe (ns).
func RouteSubscribeAt(ns netns.NsHandle, ch chan<- RouteUpdate, done <-chan struct{}

type RouteSubscribeOptions

// RouteSubscribeWithOptions work like RouteSubscribe but enable to
// provide additional options to modify the behavior. Currently, the
// namespace can be provided as well as an error callback.
func RouteSubscribeWithOptions(ch chan<- RouteUpdate, done <-chan struct{}

func routeSubscribeAt(newNs, curNs netns.NsHandle, ch chan<- RouteUpdate, done <-chan struct{}

func (p RouteProtocol) String() string {}

// genZeroIPNet returns 0.0.0.0/0 or ::/0 for IPv4 or IPv6, otherwise nil
func genZeroIPNet(family int) *net.IPNet {}