Package netutil contains network-related utility functions.
FullyQualifiedHostname returns the FQDN of the machine.
FullyQualifiedHostnameOrPanic is the same as FullyQualifiedHostname but panics in case of an error.
JoinHostPort is an extension to net.JoinHostPort that also formats the integer port.
ResolveIPv4Addrs resolves the address:port part into IP address:port pairs
SortRfc2782 reorders SRV records as specified in RFC 2782.
SplitHostPort is an alternative to net.SplitHostPort that also parses the integer port. In addition, it is more tolerant of improperly escaped IPv6 addresses, such as "::1:456", which should actually be "[::1]:456".
A ConnWithTimeouts is a wrapper to net.Comm that allows to set a read and write timeouts.
NewConnWithTimeouts wraps a net.Conn with read and write deadilnes.
Read sets a read deadilne and delegates to conn.Read.
SetDeadline implements the Conn SetDeadline method.
SetReadDeadline implements the Conn SetReadDeadline method.
SetWriteDeadline implements the Conn SetWriteDeadline method.
Write sets a write deadline and delagates to conn.Write