Documentation ¶
Overview ¶
Package format provides methods for converting various netflow-related structures and values into strings.
Index ¶
- func CIDR(ipAddr []byte, ones uint32) string
- func Direction(direction uint32) string
- func EtherType(etherTypeNumber uint32) string
- func IPAddr(ip []byte) string
- func IPProtocol(protocolNumber uint32) string
- func MacAddress(fieldValue uint64) string
- func Port(port int32) string
- func TCPFlags(flags uint32) []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CIDR ¶
CIDR formats an IP and number of bits in CIDR format (e.g. `192.1.128.64/26`). ones should be the number of ones in the bitmask, e.g. 26 in the example above.
func EtherType ¶
EtherType formats an Ether Type number as a human-readable name. https://www.iana.org/assignments/ieee-802-numbers/ieee-802-numbers.xhtml
func IPAddr ¶
IPAddr formats an IP address as a string. If the given bytes are not a valid IP address, the behavior is undefined.
func IPProtocol ¶
IPProtocol maps an IP protocol number to a standard name. https://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml
func MacAddress ¶
MacAddress formats a mac address as "xx:xx:xx:xx:xx:xx"
Types ¶
This section is empty.