Versions in this module Expand all Collapse all v0 v0.1.0 Feb 3, 2016 Changes in this version + const DEFAULT_CHANGE — linux/amd64 + const IFLA_ADDRESS — linux/amd64 + const IFLA_BRPORT_MODE — linux/amd64 + const IFLA_INFO_DATA — linux/amd64 + const IFLA_INFO_KIND — linux/amd64 + const IFLA_MACVLAN_MODE — linux/amd64 + const IFLA_NET_NS_FD — linux/amd64 + const IFLA_VLAN_ID — linux/amd64 + const IFNAMSIZ — linux/amd64 + const MACVLAN_MODE_BRIDGE — linux/amd64 + const MACVLAN_MODE_PASSTHRU — linux/amd64 + const MACVLAN_MODE_PRIVATE — linux/amd64 + const MACVLAN_MODE_VEPA — linux/amd64 + const SIOC_BRADDBR — linux/amd64 + const SIOC_BRADDIF — linux/amd64 + const SIOC_BRDELBR — linux/amd64 + const SIOC_BRDELIF — linux/amd64 + const VETH_INFO_PEER — linux/amd64 + var ErrInterfaceExists = errors.New("Network interface already exists") + var ErrNotImplemented = errors.New("not implemented") — darwin/amd64, js/wasm, windows/amd64 + var ErrShortResponse = errors.New("Got short response from netlink") + var ErrWrongSockType = errors.New("Wrong socket type") + func AddDefaultGw(ip, device string) error + func AddRoute(destination, source, gateway, device string) error + func AddToBridge(iface, master *net.Interface) error + func ChangeName(iface *net.Interface, newName string) error — linux/amd64 + func CreateBridge(name string, setMacAddr bool) error + func DelFromBridge(iface, master *net.Interface) error — linux/amd64 + func DeleteBridge(name string) error + func NetworkChangeName(iface *net.Interface, newName string) error + func NetworkCreateVethPair(name1, name2 string, txQueueLen int) error + func NetworkLinkAdd(name string, linkType string) error + func NetworkLinkAddIp(iface *net.Interface, ip net.IP, ipNet *net.IPNet) error + func NetworkLinkAddMacVlan(masterDev, macVlanDev string, mode string) error — linux/amd64 + func NetworkLinkAddMacVtap(masterDev, macVlanDev string, mode string) error — linux/amd64 + func NetworkLinkAddVlan(masterDev, vlanDev string, vlanId uint16) error — linux/amd64 + func NetworkLinkDel(name string) error + func NetworkLinkDelIp(iface *net.Interface, ip net.IP, ipNet *net.IPNet) error + func NetworkLinkDown(iface *net.Interface) error + func NetworkLinkUp(iface *net.Interface) error + func NetworkSetMTU(iface *net.Interface, mtu int) error + func NetworkSetMacAddress(iface *net.Interface, macaddr string) error — linux/amd64 + func NetworkSetMaster(iface, master *net.Interface) error + func NetworkSetNoMaster(iface *net.Interface) error — linux/amd64 + func NetworkSetNsFd(iface *net.Interface, fd int) error + func NetworkSetNsPid(iface *net.Interface, nspid int) error + func NetworkSetTxQueueLen(iface *net.Interface, txQueueLen int) error + func SetHairpinMode(iface *net.Interface, enabled bool) error — linux/amd64 + func SetMacAddress(name, addr string) error — linux/amd64 + type IfAddr struct + IP net.IP + IPNet *net.IPNet + Iface *net.Interface + type IfAddrmsg struct — linux/amd64 + func (msg *IfAddrmsg) Len() int + func (msg *IfAddrmsg) ToWireFormat() []byte + type IfInfomsg struct — linux/amd64 + func (msg *IfInfomsg) Len() int + func (msg *IfInfomsg) ToWireFormat() []byte + type MacVlanLink struct — linux/amd64 + MasterDev string + SlaveDev string + func (m MacVlanLink) Mode() uint32 + type NetlinkRequest struct — linux/amd64 + Data []NetlinkRequestData + func (rr *NetlinkRequest) AddData(data NetlinkRequestData) + func (rr *NetlinkRequest) ToWireFormat() []byte + type NetlinkRequestData interface — linux/amd64 + Len func() int + ToWireFormat func() []byte + type NetlinkSocket struct — linux/amd64 + func (s *NetlinkSocket) CheckMessage(m syscall.NetlinkMessage, seq, pid uint32) error + func (s *NetlinkSocket) Close() + func (s *NetlinkSocket) GetPid() (uint32, error) + func (s *NetlinkSocket) HandleAck(seq uint32) error + func (s *NetlinkSocket) Receive() ([]syscall.NetlinkMessage, error) + func (s *NetlinkSocket) Send(request *NetlinkRequest) error + type Route struct + Default bool + Iface *net.Interface + func NetworkGetRoutes() ([]Route, error) + type RtAttr struct — linux/amd64 + Data []byte + func (a *RtAttr) Len() int + func (a *RtAttr) ToWireFormat() []byte + type RtMsg struct — linux/amd64 + func (msg *RtMsg) Len() int + func (msg *RtMsg) ToWireFormat() []byte