Versions in this module Expand all Collapse all v0 v0.1.0 Aug 11, 2013 Changes in this version + const HeaderLen + const Version + type Conn struct + func NewConn(c net.Conn) *Conn + func (c *Conn) SetTOS(tos int) error + func (c *Conn) SetTTL(ttl int) error + func (c *Conn) TOS() (int, error) + func (c *Conn) TTL() (int, error) + type ControlFlags uint + const FlagDst + const FlagInterface + const FlagSrc + const FlagTTL + type ControlMessage struct + Dst net.IP + IfIndex int + Src net.IP + TTL int + func (cm *ControlMessage) String() string + type Header struct + Checksum int + Dst net.IP + FragOff int + ID int + Len int + Options []byte + Protocol int + Src net.IP + TOS int + TTL int + TotalLen int + Version int + func ParseHeader(b []byte) (*Header, error) + func (h *Header) Marshal() ([]byte, error) + func (h *Header) String() string + type ICMPType int + const ICMPTypeDestinationUnreachable + const ICMPTypeEcho + const ICMPTypeEchoReply + const ICMPTypeParameterProblem + const ICMPTypePhoturis + const ICMPTypeRedirect + const ICMPTypeRouterAdvertisement + const ICMPTypeRouterSolicitation + const ICMPTypeTimeExceeded + const ICMPTypeTimestamp + const ICMPTypeTimestampReply + func (typ ICMPType) String() string + type PacketConn struct + func NewPacketConn(c net.PacketConn) *PacketConn + func (c *PacketConn) Close() error + func (c *PacketConn) JoinGroup(ifi *net.Interface, group net.Addr) error + func (c *PacketConn) LeaveGroup(ifi *net.Interface, group net.Addr) error + func (c *PacketConn) MulticastInterface() (*net.Interface, error) + func (c *PacketConn) MulticastLoopback() (bool, error) + func (c *PacketConn) MulticastTTL() (int, error) + func (c *PacketConn) ReadFrom(b []byte) (n int, cm *ControlMessage, src net.Addr, err error) + func (c *PacketConn) SetControlMessage(cf ControlFlags, on bool) error + func (c *PacketConn) SetDeadline(t time.Time) error + func (c *PacketConn) SetMulticastInterface(ifi *net.Interface) error + func (c *PacketConn) SetMulticastLoopback(on bool) error + func (c *PacketConn) SetMulticastTTL(ttl int) error + func (c *PacketConn) SetReadDeadline(t time.Time) error + func (c *PacketConn) SetTOS(tos int) error + func (c *PacketConn) SetTTL(ttl int) error + func (c *PacketConn) SetWriteDeadline(t time.Time) error + func (c *PacketConn) TOS() (int, error) + func (c *PacketConn) TTL() (int, error) + func (c *PacketConn) WriteTo(b []byte, cm *ControlMessage, dst net.Addr) (n int, err error) + type RawConn struct + func NewRawConn(c net.PacketConn) (*RawConn, error) + func (c *RawConn) Close() error + func (c *RawConn) JoinGroup(ifi *net.Interface, group net.Addr) error + func (c *RawConn) LeaveGroup(ifi *net.Interface, group net.Addr) error + func (c *RawConn) MulticastInterface() (*net.Interface, error) + func (c *RawConn) MulticastLoopback() (bool, error) + func (c *RawConn) MulticastTTL() (int, error) + func (c *RawConn) ReadFrom(b []byte) (h *Header, p []byte, cm *ControlMessage, err error) + func (c *RawConn) SetControlMessage(cf ControlFlags, on bool) error + func (c *RawConn) SetDeadline(t time.Time) error + func (c *RawConn) SetMulticastInterface(ifi *net.Interface) error + func (c *RawConn) SetMulticastLoopback(on bool) error + func (c *RawConn) SetMulticastTTL(ttl int) error + func (c *RawConn) SetReadDeadline(t time.Time) error + func (c *RawConn) SetTOS(tos int) error + func (c *RawConn) SetTTL(ttl int) error + func (c *RawConn) SetWriteDeadline(t time.Time) error + func (c *RawConn) TOS() (int, error) + func (c *RawConn) TTL() (int, error) + func (c *RawConn) WriteTo(h *Header, p []byte, cm *ControlMessage) error