Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Hop ¶
type Hop struct { TryNumber int TTL int AddrIP net.IP AddrDNS []string //net.IPAddr Latency time.Duration Err error }
Hop represents a path between a source and a destination.
type TraceData ¶
type TraceData struct { Hops [][]Hop Dest net.IP Timeout time.Duration Tries int MaxTTL int Port int Proto string IPv string }
TraceData represents data received by executing traceroute.
func Exec ¶
func Exec(dest net.IP, timeout time.Duration, tries int, maxTTL int, proto string, port int) (data TraceData)
Exec returns TraceData with initialized Hops and inserts the IP version into the protocol
Click to show internal directories.
Click to hide internal directories.