Package features contains feature implementations and utility functions.
Features are split according to
* iana: features in the iana ipfix assignments (https://www.iana.org/assignments/ipfix/ipfix.xhtml) * operations: features that carry out operations (https://nta-meta-analysis.readthedocs.io/en/latest/features.html) * custom: features that don't fit the above categories * staging: experimental features
And inside those directories into the layer or general.
const InvalidSequence = -1
InvalidSequence represents an invalid sequence number
This section is empty.
GetTCP returns the TCP layer of the packet or nil
type Sequence int64
Sequence is a TCP sequence number. It provides a few convenience functions for handling TCP wrap-around. The sequence should always be in the range [0,0xFFFFFFFF]... its other bits are simply used in wrap-around calculations and should never be set.
Add adds an integer to a sequence and returns the resulting sequence.
func (Sequence) Difference ¶
Difference defines an ordering for comparing TCP sequences that's safe for roll-overs. It returns:
> 0 : if t comes after s < 0 : if t comes before s 0 : if t == s
The number returned is the sequence difference, so 4.Difference(8) will return 4.
It handles rollovers by considering any sequence in the first quarter of the uint32 space to be after any sequence in the last quarter of that space, thus wrapping the uint32 space.
type TypedSlice ¶
TypedSlice is a slice that can hold uint64, int64, bool, string, or slice
Package custom contains custom features.
|Package custom contains custom features.|
Package iana contains features as specified in the iana ipfix assignments.
|Package iana contains features as specified in the iana ipfix assignments.|
Package operations contains operations (features that use featureoutput, e.g., min).
|Package operations contains operations (features that use featureoutput, e.g., min).|
Package staging contains custom features that are subject to change.
|Package staging contains custom features that are subject to change.|