Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ICMP ¶
type ICMP struct {
Code uint8 `json:"code"`
Type uint8 `json:"type"`
Description string `json:"description"`
Extensions []ICMPExtension `json:"extensions"`
MPLSLabels []MPLSLabel `json:"mpls_labels"`
}
ICMP represents some information from the ICMP header.
type ICMPExtension ¶
type ICMPExtension struct {
Class uint8 `json:"class"`
Type uint8 `json:"type"`
Payload []byte `json:"payload"`
Size uint8 `json:"size"`
}
ICMPExtension represents the ICMP extension header.
type IP ¶
type IP struct {
SrcIP net.IP `json:"src"`
DstIP net.IP `json:"dst"`
ID uint16 `json:"id"`
TTL uint8 `json:"ttl"`
}
IP represents some information from the IP header.
type MPLSLabel ¶
type MPLSLabel struct {
BottomOfStack uint8 `json:"bottom_of_stack"`
Experimental uint8 `json:"experimental"`
Label uint32 `json:"label"`
TTL uint8 `json:"ttl"`
}
MPLSLabel represents an MPLS label in an ICMP header.
type Packet ¶
type Packet struct {
Timestamp UnixUsec `json:"timestamp"`
IP IP `json:"ip"`
UDP *UDP `json:"udp,omitempty"`
ICMP *ICMP `json:"icmp,omitempty"`
}
Packet represents some information of a sent or received packet.
type Probe ¶
type Probe struct {
Flowhash uint16 `json:"flowhash"`
IsLast bool `json:"is_last"`
Name string `json:"name"`
NATID uint16 `json:"nat_id"`
RttUsec uint64 `json:"rtt_usec"`
Sent Packet `json:"sent"`
Received *Packet `json:"received"`
ZeroTTLForwardingBug bool `json:"zerottl_forwarding_bug"`
}
Probe holds information about a dublin-traceroute probe.
type Results ¶
type Results struct {
Flows map[uint16][]Probe `json:"flows"`
// contains filtered or unexported fields
}
Results is the main container type for a dublin-traceroute set of results.
type UnixUsec ¶
UnixUsec is UNIX time in the form sec.usec
func (UnixUsec) MarshalJSON ¶
MarshalJSON serializes an UnixUsec object into a seconds.microseconds representation.
func (*UnixUsec) UnmarshalJSON ¶
UnmarshalJSON deserializes a seconds.microseconds timestamp into an UnixUsec object. The timestamp can be optionally surrounded by double quotes.