Imports #
"syscall"
"syscall"
"unsafe"
"unsafe"
"syscall"
"unsafe"
"errors"
"syscall"
"unsafe"
"syscall"
"syscall"
"unsafe"
"unsafe"
"syscall"
"unsafe"
"errors"
"syscall"
"unsafe"
var bigEndian binaryBigEndian
var littleEndian binaryLittleEndian
var nativeEndian binaryByteOrder
var procIoctl uintptr
const sizeofLifIfinfoReq = 0x10
const sizeofLifconf = 0x18
const sizeofLifnum = 0xc
const sizeofLifreq = 0x178
const sysLIFC_ALLZONES = 0x8
const sysLIFC_ENABLED = 0x20
const sysLIFC_EXTERNAL_SOURCE = 0x2
const sysLIFC_NOXMIT = 0x1
const sysLIFC_TEMPORARY = 0x4
const sysLIFC_UNDER_IPMP = 0x10
An Addr represents an address associated with packet routing.
type Addr interface {
Family() int
}
type binaryByteOrder interface {
Uint16([]byte) uint16
Uint32([]byte) uint32
Uint64([]byte) uint64
PutUint16([]byte, uint16)
PutUint32([]byte, uint32)
PutUint64([]byte, uint64)
}
An Inet4Addr represents an internet address for IPv4.
type Inet4Addr struct {
IP [4]byte
PrefixLen int
}
An Inet6Addr represents an internet address for IPv6.
type Inet6Addr struct {
IP [16]byte
PrefixLen int
ZoneID int
}
A Link represents logical data link information. It also represents base information for logical network interface. On Solaris, each logical network interface represents network layer adjacency information and the interface has a only single network address or address pair for tunneling. It's usual that multiple logical network interfaces share the same logical data link.
type Link struct {
Name string
Index int
Type int
Flags int
MTU int
Addr []byte
}
type binaryBigEndian struct {
}
type binaryLittleEndian struct {
}
type endpoint struct {
af int
s uintptr
}
type lifIfinfoReq struct {
Maxhops uint8
Pad_cgo_0 [3]byte
Reachtime uint32
Reachretrans uint32
Maxmtu uint32
}
type lifconf struct {
Family uint16
Pad_cgo_0 [2]byte
Flags int32
Len int32
Pad_cgo_1 [4]byte
Lifcu [8]byte
}
type lifnum struct {
Family uint16
Pad_cgo_0 [2]byte
Flags int32
Count int32
}
type lifreq struct {
Name [32]int8
Lifru1 [4]byte
Type uint32
Lifru [336]byte
}
type sockaddrStorage struct {
Family uint16
X_ss_pad1 [6]int8
X_ss_align float64
X_ss_pad2 [240]int8
}
Addrs returns a list of interface addresses. The provided af must be an address family and name must be a data link name. The zero value of af or name means a wildcard.
func Addrs(af int, name string) ([]Addr, error)
Family implements the Family method of Addr interface.
func (a *Inet6Addr) Family() int
Family implements the Family method of Addr interface.
func (a *Inet4Addr) Family() int
Links returns a list of logical data links. The provided af must be an address family and name must be a data link name. The zero value of af or name means a wildcard.
func Links(af int, name string) ([]Link, error)
func (binaryLittleEndian) PutUint16(b []byte, v uint16)
func (binaryBigEndian) PutUint16(b []byte, v uint16)
func (binaryLittleEndian) PutUint32(b []byte, v uint32)
func (binaryBigEndian) PutUint32(b []byte, v uint32)
func (binaryLittleEndian) PutUint64(b []byte, v uint64)
func (binaryBigEndian) PutUint64(b []byte, v uint64)
func (binaryLittleEndian) Uint16(b []byte) uint16
func (binaryBigEndian) Uint16(b []byte) uint16
func (binaryBigEndian) Uint32(b []byte) uint32
func (binaryLittleEndian) Uint32(b []byte) uint32
func (binaryBigEndian) Uint64(b []byte) uint64
func (binaryLittleEndian) Uint64(b []byte) uint64
func (ep *endpoint) close() error
func (ll *Link) fetch(s uintptr)
func init()
func ioctl(s uintptr, ioc uintptr, arg unsafe.Pointer) error
func isDupLink(lls []Link, name string) bool
func links(eps []endpoint, name string) ([]Link, error)
func newEndpoints(af int) ([]endpoint, error)
func parseLinkAddr(b []byte) ([]byte, error)
func sysvicall6(trap uintptr, nargs uintptr, a1 uintptr, a2 uintptr, a3 uintptr, a4 uintptr, a5 uintptr, a6 uintptr) (uintptr, uintptr, syscall.Errno)
Generated with Arrow