Documentation ¶
Index ¶
- Constants
- Variables
- func BPFFilterToRaw(linkType layers.LinkType, captureLength uint32, filter string) ([]bpf.RawInstruction, error)
- func DefaultLayerKeyModeName() string
- func GetFirstLayerType(encapType string) (gopacket.LayerType, layers.LinkType)
- func LayersPath(ls []gopacket.Layer) (string, string)
- func NewFilterForFlowSet(flowset *FlowSet) *filters.Filter
- func NewFilterForNodeTIDs(uuids []string) *filters.Filter
- func NewFilterForNodes(nodes []*graph.Node) *filters.Filter
- func SetEBPFKernFlow(ebpfFlow *EBPFFlow, kernFlow unsafe.Pointer)
- func UnixMilli(t time.Time) int64
- type ApplicationPortMap
- type BPF
- type EBPFFlow
- type ExtFlow
- type ExtFlowType
- type ExtraLayers
- type Flow
- func (*Flow) Descriptor() ([]byte, []int)
- func (m *Flow) GetApplication() string
- func (m *Flow) GetCaptureID() string
- func (m *Flow) GetDHCPv4() *layers.DHCPv4
- func (m *Flow) GetDNS() *layers.DNS
- func (f *Flow) GetField(field string) (interface{}, error)
- func (f *Flow) GetFieldBool(field string) (bool, error)
- func (f *Flow) GetFieldInt64(field string) (_ int64, err error)
- func (f *Flow) GetFieldKeys() []string
- func (f *Flow) GetFieldString(field string) (string, error)
- func (m *Flow) GetFinishType() FlowFinishType
- func (m *Flow) GetICMP() *ICMPLayer
- func (m *Flow) GetIPMetric() *IPMetric
- func (m *Flow) GetL3TrackingID() string
- func (m *Flow) GetLast() int64
- func (m *Flow) GetLastRawPackets() []*RawPacket
- func (m *Flow) GetLastUpdateMetric() *FlowMetric
- func (m *Flow) GetLayersPath() string
- func (m *Flow) GetLink() *FlowLayer
- func (m *Flow) GetMetric() *FlowMetric
- func (m *Flow) GetNetwork() *FlowLayer
- func (m *Flow) GetNodeTID() string
- func (m *Flow) GetParentUUID() string
- func (m *Flow) GetRawPacketsCaptured() int64
- func (m *Flow) GetStart() int64
- func (m *Flow) GetTCPMetric() *TCPMetric
- func (m *Flow) GetTrackingID() string
- func (m *Flow) GetTransport() *TransportLayer
- func (m *Flow) GetUUID() string
- func (m *Flow) GetVRRPv2() *layers.VRRPv2
- func (f *Flow) Init(now int64, parentUUID string, uuids *UUIDs)
- func (f *Flow) LinkType() (layers.LinkType, error)
- func (m *Flow) Marshal() (dAtA []byte, err error)
- func (v Flow) MarshalEasyJSON(w *jwriter.Writer)
- func (v Flow) MarshalJSON() ([]byte, error)
- func (m *Flow) MarshalTo(dAtA []byte) (int, error)
- func (m *Flow) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (f *Flow) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (f *Flow) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (f *Flow) MatchString(key string, predicate getter.StringPredicate) bool
- func (*Flow) ProtoMessage()
- func (m *Flow) ProtoSize() (n int)
- func (m *Flow) Reset()
- func (f *Flow) SetUUIDs(key uint64, opts Opts) (uint64, uint64)
- func (m *Flow) String() string
- func (m *Flow) Unmarshal(dAtA []byte) error
- func (v *Flow) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *Flow) UnmarshalJSON(data []byte) error
- func (f *Flow) Update(packet *Packet, opts *Opts)
- func (m *Flow) XXX_DiscardUnknown()
- func (m *Flow) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Flow) XXX_Merge(src proto.Message)
- func (m *Flow) XXX_Size() int
- func (m *Flow) XXX_Unmarshal(b []byte) error
- type FlowFinishType
- type FlowLayer
- func (*FlowLayer) Descriptor() ([]byte, []int)
- func (m *FlowLayer) GetA() string
- func (m *FlowLayer) GetB() string
- func (obj *FlowLayer) GetField(key string) (interface{}, error)
- func (obj *FlowLayer) GetFieldBool(key string) (bool, error)
- func (obj *FlowLayer) GetFieldInt64(key string) (int64, error)
- func (obj *FlowLayer) GetFieldKeys() []string
- func (obj *FlowLayer) GetFieldString(key string) (string, error)
- func (m *FlowLayer) GetID() int64
- func (m *FlowLayer) GetProtocol() FlowProtocol
- func (fl *FlowLayer) Hash(hasher hash.Hash, swap bool)
- func (m *FlowLayer) Marshal() (dAtA []byte, err error)
- func (v FlowLayer) MarshalEasyJSON(w *jwriter.Writer)
- func (v FlowLayer) MarshalJSON() ([]byte, error)
- func (m *FlowLayer) MarshalTo(dAtA []byte) (int, error)
- func (m *FlowLayer) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (obj *FlowLayer) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (obj *FlowLayer) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (obj *FlowLayer) MatchString(key string, predicate getter.StringPredicate) bool
- func (*FlowLayer) ProtoMessage()
- func (m *FlowLayer) ProtoSize() (n int)
- func (m *FlowLayer) Reset()
- func (m *FlowLayer) String() string
- func (m *FlowLayer) Unmarshal(dAtA []byte) error
- func (v *FlowLayer) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *FlowLayer) UnmarshalJSON(data []byte) error
- func (m *FlowLayer) XXX_DiscardUnknown()
- func (m *FlowLayer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *FlowLayer) XXX_Merge(src proto.Message)
- func (m *FlowLayer) XXX_Size() int
- func (m *FlowLayer) XXX_Unmarshal(b []byte) error
- type FlowMetric
- func (fm *FlowMetric) Add(m common.Metric) common.Metric
- func (*FlowMetric) Descriptor() ([]byte, []int)
- func (m *FlowMetric) GetABBytes() int64
- func (m *FlowMetric) GetABPackets() int64
- func (m *FlowMetric) GetBABytes() int64
- func (m *FlowMetric) GetBAPackets() int64
- func (obj *FlowMetric) GetField(key string) (interface{}, error)
- func (obj *FlowMetric) GetFieldBool(key string) (bool, error)
- func (obj *FlowMetric) GetFieldInt64(key string) (int64, error)
- func (obj *FlowMetric) GetFieldKeys() []string
- func (obj *FlowMetric) GetFieldString(key string) (string, error)
- func (m *FlowMetric) GetLast() int64
- func (m *FlowMetric) GetRTT() int64
- func (m *FlowMetric) GetStart() int64
- func (fm *FlowMetric) IsZero() bool
- func (m *FlowMetric) Marshal() (dAtA []byte, err error)
- func (v FlowMetric) MarshalEasyJSON(w *jwriter.Writer)
- func (v FlowMetric) MarshalJSON() ([]byte, error)
- func (m *FlowMetric) MarshalTo(dAtA []byte) (int, error)
- func (m *FlowMetric) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (obj *FlowMetric) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (obj *FlowMetric) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (obj *FlowMetric) MatchString(key string, predicate getter.StringPredicate) bool
- func (*FlowMetric) ProtoMessage()
- func (m *FlowMetric) ProtoSize() (n int)
- func (m *FlowMetric) Reset()
- func (fm *FlowMetric) SetLast(last int64)
- func (fm *FlowMetric) SetStart(start int64)
- func (fm *FlowMetric) Split(cut int64) (common.Metric, common.Metric)
- func (m *FlowMetric) String() string
- func (fm *FlowMetric) Sub(m common.Metric) common.Metric
- func (m *FlowMetric) Unmarshal(dAtA []byte) error
- func (v *FlowMetric) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *FlowMetric) UnmarshalJSON(data []byte) error
- func (m *FlowMetric) XXX_DiscardUnknown()
- func (m *FlowMetric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *FlowMetric) XXX_Merge(src proto.Message)
- func (m *FlowMetric) XXX_Size() int
- func (m *FlowMetric) XXX_Unmarshal(b []byte) error
- type FlowProtocol
- type FlowSearchReply
- func (*FlowSearchReply) Descriptor() ([]byte, []int)
- func (m *FlowSearchReply) GetFlowSet() *FlowSet
- func (m *FlowSearchReply) Marshal() (dAtA []byte, err error)
- func (v FlowSearchReply) MarshalEasyJSON(w *jwriter.Writer)
- func (v FlowSearchReply) MarshalJSON() ([]byte, error)
- func (m *FlowSearchReply) MarshalTo(dAtA []byte) (int, error)
- func (m *FlowSearchReply) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*FlowSearchReply) ProtoMessage()
- func (m *FlowSearchReply) ProtoSize() (n int)
- func (m *FlowSearchReply) Reset()
- func (m *FlowSearchReply) String() string
- func (m *FlowSearchReply) Unmarshal(dAtA []byte) error
- func (v *FlowSearchReply) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *FlowSearchReply) UnmarshalJSON(data []byte) error
- func (m *FlowSearchReply) XXX_DiscardUnknown()
- func (m *FlowSearchReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *FlowSearchReply) XXX_Merge(src proto.Message)
- func (m *FlowSearchReply) XXX_Size() int
- func (m *FlowSearchReply) XXX_Unmarshal(b []byte) error
- type FlowSet
- func (fs *FlowSet) Dedup(field string) error
- func (*FlowSet) Descriptor() ([]byte, []int)
- func (fs *FlowSet) Filter(filter *filters.Filter) *FlowSet
- func (m *FlowSet) GetEnd() int64
- func (m *FlowSet) GetFlows() []*Flow
- func (m *FlowSet) GetStart() int64
- func (m *FlowSet) Marshal() (dAtA []byte, err error)
- func (v FlowSet) MarshalEasyJSON(w *jwriter.Writer)
- func (v FlowSet) MarshalJSON() ([]byte, error)
- func (m *FlowSet) MarshalTo(dAtA []byte) (int, error)
- func (m *FlowSet) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (fs *FlowSet) Merge(ofs *FlowSet, context MergeContext) error
- func (*FlowSet) ProtoMessage()
- func (m *FlowSet) ProtoSize() (n int)
- func (m *FlowSet) Reset()
- func (fs *FlowSet) Slice(from, to int)
- func (fs *FlowSet) Sort(order filters.SortOrder, orderBy string)
- func (m *FlowSet) String() string
- func (m *FlowSet) Unmarshal(dAtA []byte) error
- func (v *FlowSet) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *FlowSet) UnmarshalJSON(data []byte) error
- func (m *FlowSet) XXX_DiscardUnknown()
- func (m *FlowSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *FlowSet) XXX_Merge(src proto.Message)
- func (m *FlowSet) XXX_Size() int
- func (m *FlowSet) XXX_Unmarshal(b []byte) error
- type ICMPLayer
- func (*ICMPLayer) Descriptor() ([]byte, []int)
- func (m *ICMPLayer) GetCode() uint32
- func (obj *ICMPLayer) GetField(key string) (interface{}, error)
- func (obj *ICMPLayer) GetFieldBool(key string) (bool, error)
- func (obj *ICMPLayer) GetFieldInt64(key string) (int64, error)
- func (obj *ICMPLayer) GetFieldKeys() []string
- func (obj *ICMPLayer) GetFieldString(key string) (string, error)
- func (m *ICMPLayer) GetID() uint32
- func (m *ICMPLayer) GetType() ICMPType
- func (fl *ICMPLayer) Hash(hasher hash.Hash)
- func (m *ICMPLayer) Marshal() (dAtA []byte, err error)
- func (v ICMPLayer) MarshalEasyJSON(w *jwriter.Writer)
- func (v ICMPLayer) MarshalJSON() ([]byte, error)
- func (m *ICMPLayer) MarshalTo(dAtA []byte) (int, error)
- func (m *ICMPLayer) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (obj *ICMPLayer) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (obj *ICMPLayer) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (obj *ICMPLayer) MatchString(key string, predicate getter.StringPredicate) bool
- func (*ICMPLayer) ProtoMessage()
- func (m *ICMPLayer) ProtoSize() (n int)
- func (m *ICMPLayer) Reset()
- func (m *ICMPLayer) String() string
- func (m *ICMPLayer) Unmarshal(dAtA []byte) error
- func (v *ICMPLayer) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *ICMPLayer) UnmarshalJSON(data []byte) error
- func (m *ICMPLayer) XXX_DiscardUnknown()
- func (m *ICMPLayer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ICMPLayer) XXX_Merge(src proto.Message)
- func (m *ICMPLayer) XXX_Size() int
- func (m *ICMPLayer) XXX_Unmarshal(b []byte) error
- type ICMPType
- type ICMPv4
- type ICMPv6
- type IPDefragger
- type IPDefraggerMetric
- type IPMetric
- func (*IPMetric) Descriptor() ([]byte, []int)
- func (obj *IPMetric) GetField(key string) (interface{}, error)
- func (obj *IPMetric) GetFieldBool(key string) (bool, error)
- func (obj *IPMetric) GetFieldInt64(key string) (int64, error)
- func (obj *IPMetric) GetFieldKeys() []string
- func (obj *IPMetric) GetFieldString(key string) (string, error)
- func (m *IPMetric) GetFragmentErrors() int64
- func (m *IPMetric) GetFragments() int64
- func (m *IPMetric) Marshal() (dAtA []byte, err error)
- func (v IPMetric) MarshalEasyJSON(w *jwriter.Writer)
- func (v IPMetric) MarshalJSON() ([]byte, error)
- func (m *IPMetric) MarshalTo(dAtA []byte) (int, error)
- func (m *IPMetric) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (obj *IPMetric) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (obj *IPMetric) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (obj *IPMetric) MatchString(key string, predicate getter.StringPredicate) bool
- func (*IPMetric) ProtoMessage()
- func (m *IPMetric) ProtoSize() (n int)
- func (m *IPMetric) Reset()
- func (m *IPMetric) String() string
- func (m *IPMetric) Unmarshal(dAtA []byte) error
- func (v *IPMetric) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *IPMetric) UnmarshalJSON(data []byte) error
- func (m *IPMetric) XXX_DiscardUnknown()
- func (m *IPMetric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *IPMetric) XXX_Merge(src proto.Message)
- func (m *IPMetric) XXX_Size() int
- func (m *IPMetric) XXX_Unmarshal(b []byte) error
- type LayerKeyMode
- type MergeContext
- type Message
- func (*Message) Descriptor() ([]byte, []int)
- func (m *Message) GetFlows() []*Flow
- func (m *Message) GetStats() *Stats
- func (m *Message) Marshal() (dAtA []byte, err error)
- func (v Message) MarshalEasyJSON(w *jwriter.Writer)
- func (v Message) MarshalJSON() ([]byte, error)
- func (m *Message) MarshalTo(dAtA []byte) (int, error)
- func (m *Message) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Message) ProtoMessage()
- func (m *Message) ProtoSize() (n int)
- func (m *Message) Reset()
- func (m *Message) String() string
- func (m *Message) Unmarshal(dAtA []byte) error
- func (v *Message) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *Message) UnmarshalJSON(data []byte) error
- func (m *Message) XXX_DiscardUnknown()
- func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Message) XXX_Merge(src proto.Message)
- func (m *Message) XXX_Size() int
- func (m *Message) XXX_Unmarshal(b []byte) error
- type Operation
- type OperationType
- type Opts
- type Packet
- func (p *Packet) ApplicationFlow() (gopacket.Flow, error)
- func (p *Packet) Keys(parentUUID string, uuids *UUIDs, opts *Opts) (uint64, uint64, uint64)
- func (p *Packet) Layer(t gopacket.LayerType) gopacket.Layer
- func (p *Packet) LinkLayer() gopacket.LinkLayer
- func (p *Packet) NetworkLayer() gopacket.NetworkLayer
- func (p *Packet) TransportFlow(swap bool) (gopacket.Flow, error)
- func (p *Packet) TransportLayer() gopacket.TransportLayer
- type PacketSequence
- type PcapTableFeeder
- type PcapWriter
- type RawPacket
- func (*RawPacket) Descriptor() ([]byte, []int)
- func (m *RawPacket) GetData() []byte
- func (m *RawPacket) GetIndex() int64
- func (m *RawPacket) GetLinkType() github_com_google_gopacket_layers.LinkType
- func (m *RawPacket) GetTimestamp() int64
- func (m *RawPacket) Marshal() (dAtA []byte, err error)
- func (v RawPacket) MarshalEasyJSON(w *jwriter.Writer)
- func (v RawPacket) MarshalJSON() ([]byte, error)
- func (m *RawPacket) MarshalTo(dAtA []byte) (int, error)
- func (m *RawPacket) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*RawPacket) ProtoMessage()
- func (m *RawPacket) ProtoSize() (n int)
- func (m *RawPacket) Reset()
- func (m *RawPacket) String() string
- func (m *RawPacket) Unmarshal(dAtA []byte) error
- func (v *RawPacket) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *RawPacket) UnmarshalJSON(data []byte) error
- func (m *RawPacket) XXX_DiscardUnknown()
- func (m *RawPacket) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *RawPacket) XXX_Merge(src proto.Message)
- func (m *RawPacket) XXX_Size() int
- func (m *RawPacket) XXX_Unmarshal(b []byte) error
- type Sender
- type Stats
- func (*Stats) Descriptor() ([]byte, []int)
- func (m *Stats) GetCaptureID() string
- func (m *Stats) GetFlowCount() int64
- func (m *Stats) GetFlowDropped() int64
- func (m *Stats) GetKernelFlowDropped() int64
- func (m *Stats) GetPacketsDropped() int64
- func (m *Stats) GetPacketsReceived() int64
- func (m *Stats) Marshal() (dAtA []byte, err error)
- func (v Stats) MarshalEasyJSON(w *jwriter.Writer)
- func (v Stats) MarshalJSON() ([]byte, error)
- func (m *Stats) MarshalTo(dAtA []byte) (int, error)
- func (m *Stats) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Stats) ProtoMessage()
- func (m *Stats) ProtoSize() (n int)
- func (m *Stats) Reset()
- func (m *Stats) String() string
- func (m *Stats) Unmarshal(dAtA []byte) error
- func (v *Stats) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *Stats) UnmarshalJSON(data []byte) error
- func (m *Stats) XXX_DiscardUnknown()
- func (m *Stats) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Stats) XXX_Merge(src proto.Message)
- func (m *Stats) XXX_Size() int
- func (m *Stats) XXX_Unmarshal(b []byte) error
- type TCPAssembler
- type TCPAssemblerStream
- type TCPMetric
- func (*TCPMetric) Descriptor() ([]byte, []int)
- func (m *TCPMetric) GetABBytes() int64
- func (m *TCPMetric) GetABFinStart() int64
- func (m *TCPMetric) GetABPackets() int64
- func (m *TCPMetric) GetABRstStart() int64
- func (m *TCPMetric) GetABSawEnd() int64
- func (m *TCPMetric) GetABSawStart() int64
- func (m *TCPMetric) GetABSegmentOutOfOrder() int64
- func (m *TCPMetric) GetABSegmentSkipped() int64
- func (m *TCPMetric) GetABSegmentSkippedBytes() int64
- func (m *TCPMetric) GetABSynStart() int64
- func (m *TCPMetric) GetABSynTTL() uint32
- func (m *TCPMetric) GetBABytes() int64
- func (m *TCPMetric) GetBAFinStart() int64
- func (m *TCPMetric) GetBAPackets() int64
- func (m *TCPMetric) GetBARstStart() int64
- func (m *TCPMetric) GetBASawEnd() int64
- func (m *TCPMetric) GetBASawStart() int64
- func (m *TCPMetric) GetBASegmentOutOfOrder() int64
- func (m *TCPMetric) GetBASegmentSkipped() int64
- func (m *TCPMetric) GetBASegmentSkippedBytes() int64
- func (m *TCPMetric) GetBASynStart() int64
- func (m *TCPMetric) GetBASynTTL() uint32
- func (obj *TCPMetric) GetField(key string) (interface{}, error)
- func (obj *TCPMetric) GetFieldBool(key string) (bool, error)
- func (obj *TCPMetric) GetFieldInt64(key string) (int64, error)
- func (obj *TCPMetric) GetFieldKeys() []string
- func (obj *TCPMetric) GetFieldString(key string) (string, error)
- func (m *TCPMetric) Marshal() (dAtA []byte, err error)
- func (v TCPMetric) MarshalEasyJSON(w *jwriter.Writer)
- func (v TCPMetric) MarshalJSON() ([]byte, error)
- func (m *TCPMetric) MarshalTo(dAtA []byte) (int, error)
- func (m *TCPMetric) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (obj *TCPMetric) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (obj *TCPMetric) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (obj *TCPMetric) MatchString(key string, predicate getter.StringPredicate) bool
- func (*TCPMetric) ProtoMessage()
- func (m *TCPMetric) ProtoSize() (n int)
- func (m *TCPMetric) Reset()
- func (m *TCPMetric) String() string
- func (m *TCPMetric) Unmarshal(dAtA []byte) error
- func (v *TCPMetric) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *TCPMetric) UnmarshalJSON(data []byte) error
- func (m *TCPMetric) XXX_DiscardUnknown()
- func (m *TCPMetric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TCPMetric) XXX_Merge(src proto.Message)
- func (m *TCPMetric) XXX_Size() int
- func (m *TCPMetric) XXX_Unmarshal(b []byte) error
- type Table
- func (ft *Table) FeedWithGoPacket(packet gopacket.Packet, bpf *BPF)
- func (ft *Table) FeedWithSFlowSample(sample *layers.SFlowFlowSample, bpf *BPF)
- func (ft *Table) IPDefragger() *IPDefragger
- func (ft *Table) Query(query *TableQuery) []byte
- func (ft *Table) Run()
- func (ft *Table) Start(extFlowExp chan interface{}) (chan *PacketSequence, chan *ExtFlow, chan Stats)
- func (ft *Table) State() service.State
- func (ft *Table) Stop()
- type TableAllocator
- type TableClient
- type TableOpts
- type TableQuery
- func (*TableQuery) Descriptor() ([]byte, []int)
- func (m *TableQuery) GetQuery() *filters.SearchQuery
- func (m *TableQuery) GetType() string
- func (m *TableQuery) Marshal() (dAtA []byte, err error)
- func (v TableQuery) MarshalEasyJSON(w *jwriter.Writer)
- func (v TableQuery) MarshalJSON() ([]byte, error)
- func (m *TableQuery) MarshalTo(dAtA []byte) (int, error)
- func (m *TableQuery) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*TableQuery) ProtoMessage()
- func (m *TableQuery) ProtoSize() (n int)
- func (m *TableQuery) Reset()
- func (m *TableQuery) String() string
- func (m *TableQuery) Unmarshal(dAtA []byte) error
- func (v *TableQuery) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *TableQuery) UnmarshalJSON(data []byte) error
- func (m *TableQuery) XXX_DiscardUnknown()
- func (m *TableQuery) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TableQuery) XXX_Merge(src proto.Message)
- func (m *TableQuery) XXX_Size() int
- func (m *TableQuery) XXX_Unmarshal(b []byte) error
- type TableReply
- func (*TableReply) Descriptor() ([]byte, []int)
- func (m *TableReply) GetFlowSetBytes() [][]byte
- func (m *TableReply) GetStatus() int32
- func (m *TableReply) Marshal() (dAtA []byte, err error)
- func (v TableReply) MarshalEasyJSON(w *jwriter.Writer)
- func (v TableReply) MarshalJSON() ([]byte, error)
- func (m *TableReply) MarshalTo(dAtA []byte) (int, error)
- func (m *TableReply) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*TableReply) ProtoMessage()
- func (m *TableReply) ProtoSize() (n int)
- func (m *TableReply) Reset()
- func (m *TableReply) String() string
- func (m *TableReply) Unmarshal(dAtA []byte) error
- func (v *TableReply) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *TableReply) UnmarshalJSON(data []byte) error
- func (m *TableReply) XXX_DiscardUnknown()
- func (m *TableReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TableReply) XXX_Merge(src proto.Message)
- func (m *TableReply) XXX_Size() int
- func (m *TableReply) XXX_Unmarshal(b []byte) error
- type TransportLayer
- func (*TransportLayer) Descriptor() ([]byte, []int)
- func (m *TransportLayer) GetA() int64
- func (m *TransportLayer) GetB() int64
- func (obj *TransportLayer) GetField(key string) (interface{}, error)
- func (obj *TransportLayer) GetFieldBool(key string) (bool, error)
- func (obj *TransportLayer) GetFieldInt64(key string) (int64, error)
- func (obj *TransportLayer) GetFieldKeys() []string
- func (obj *TransportLayer) GetFieldString(key string) (string, error)
- func (m *TransportLayer) GetID() int64
- func (m *TransportLayer) GetProtocol() FlowProtocol
- func (tl *TransportLayer) Hash(hasher hash.Hash, swap bool)
- func (m *TransportLayer) Marshal() (dAtA []byte, err error)
- func (v TransportLayer) MarshalEasyJSON(w *jwriter.Writer)
- func (v TransportLayer) MarshalJSON() ([]byte, error)
- func (m *TransportLayer) MarshalTo(dAtA []byte) (int, error)
- func (m *TransportLayer) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (obj *TransportLayer) MatchBool(key string, predicate getter.BoolPredicate) bool
- func (obj *TransportLayer) MatchInt64(key string, predicate getter.Int64Predicate) bool
- func (obj *TransportLayer) MatchString(key string, predicate getter.StringPredicate) bool
- func (*TransportLayer) ProtoMessage()
- func (m *TransportLayer) ProtoSize() (n int)
- func (m *TransportLayer) Reset()
- func (m *TransportLayer) String() string
- func (m *TransportLayer) Unmarshal(dAtA []byte) error
- func (v *TransportLayer) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *TransportLayer) UnmarshalJSON(data []byte) error
- func (m *TransportLayer) XXX_DiscardUnknown()
- func (m *TransportLayer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TransportLayer) XXX_Merge(src proto.Message)
- func (m *TransportLayer) XXX_Size() int
- func (m *TransportLayer) XXX_Unmarshal(b []byte) error
- type UUIDs
- type WSTableClient
- type WSTableServer
Constants ¶
const ( // DefaultCaptureLength : default packet capture length DefaultCaptureLength uint32 = 256 // MaxCaptureLength : maximum capture length accepted MaxCaptureLength uint32 = 4096 // MaxRawPacketLimit : maximum raw packet captured, limitation could be removed once flow over tcp MaxRawPacketLimit uint32 = 10 // DefaultProtobufFlowSize : the default protobuf size without any raw packet for a flow DefaultProtobufFlowSize = 500 )
const ( // OperationExtFlowType classic flow passed as Operation OperationExtFlowType = iota // EBPFExtFlowType type of eBPF flow EBPFExtFlowType )
const HoldTimeoutMilliseconds = int64(time.Duration(15) * time.Second / time.Millisecond)
HoldTimeoutMilliseconds is the number of milliseconds for holding ended flows before they get deleted from the flow table
const (
Namespace = "Flow"
)
Namespace "Flow"
Variables ¶
var ( // ErrFlowProtocol invalid protocol error ErrFlowProtocol = errors.New("FlowProtocol invalid") // ErrLayerNotFound layer not present in the packet ErrLayerNotFound = errors.New("Layer not found") )
var ( ErrInvalidLengthFlow = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowFlow = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupFlow = fmt.Errorf("proto: unexpected end of group") )
var FlowFinishType_name = map[int32]string{
0: "NOT_FINISHED",
1: "TIMEOUT",
2: "TCP_FIN",
3: "TCP_RST",
}
var FlowFinishType_value = map[string]int32{
"NOT_FINISHED": 0,
"TIMEOUT": 1,
"TCP_FIN": 2,
"TCP_RST": 3,
}
var FlowProtocol_name = map[int32]string{
0: "ETHERNET",
1: "IPV4",
2: "TCP",
3: "UDP",
4: "SCTP",
5: "IPV6",
6: "ICMPV4",
7: "ICMPV6",
}
var FlowProtocol_value = map[string]int32{
"ETHERNET": 0,
"IPV4": 1,
"TCP": 2,
"UDP": 3,
"SCTP": 4,
"IPV6": 5,
"ICMPV4": 6,
"ICMPV6": 7,
}
var ICMPType_name = map[int32]string{
0: "UNKNOWN",
1: "DESTINATION_UNREACHABLE",
2: "ECHO",
3: "NEIGHBOR",
4: "ADDRESS_MASK",
5: "INFO",
6: "PARAMETER_PROBLEM",
7: "REDIRECT",
8: "ROUTER",
9: "SOURCE_QUENCH",
10: "TIME_EXCEEDED",
11: "TIMESTAMP",
12: "PACKET_TOO_BIG",
}
var ICMPType_value = map[string]int32{
"UNKNOWN": 0,
"DESTINATION_UNREACHABLE": 1,
"ECHO": 2,
"NEIGHBOR": 3,
"ADDRESS_MASK": 4,
"INFO": 5,
"PARAMETER_PROBLEM": 6,
"REDIRECT": 7,
"ROUTER": 8,
"SOURCE_QUENCH": 9,
"TIME_EXCEEDED": 10,
"TIMESTAMP": 11,
"PACKET_TOO_BIG": 12,
}
var LayerTypeERSPanII = gopacket.RegisterLayerType(55557, gopacket.LayerTypeMetadata{Name: "LayerTypeERSPanII", Decoder: gopacket.DecodeFunc(decodeERSpanIILayer)})
LayerTypeERSPanII decoder
var LayerTypeRawIP = gopacket.RegisterLayerType(55555, gopacket.LayerTypeMetadata{Name: "LayerTypeRawIP", Decoder: gopacket.DecodeFunc(decodeInGRELayer)})
LayerTypeRawIP creates a layer type, should be unique and high, so it doesn't conflict, giving it a name and a decoder to use.
Functions ¶
func BPFFilterToRaw ¶ added in v0.10.0
func BPFFilterToRaw(linkType layers.LinkType, captureLength uint32, filter string) ([]bpf.RawInstruction, error)
BPFFilterToRaw creates a raw binary filter from a BPF expression
func DefaultLayerKeyModeName ¶ added in v0.18.0
func DefaultLayerKeyModeName() string
DefaultLayerKeyModeName returns the default layer key mode
func GetFirstLayerType ¶ added in v0.17.0
GetFirstLayerType returns layer type and link type according to the given encapsulation
func LayersPath ¶ added in v0.18.0
LayersPath returns path and the application of all the layers separated by a slash.
func NewFilterForFlowSet ¶ added in v0.10.0
NewFilterForFlowSet creates a new filter based on a set of flows
func NewFilterForNodeTIDs ¶ added in v0.10.0
NewFilterForNodeTIDs creates a new filter based on flow NodeTID
func NewFilterForNodes ¶ added in v0.5.0
NewFilterForNodes creates a new filter based on graph nodes
func SetEBPFKernFlow ¶ added in v0.24.0
SetEBPFKernFlow is an helper function that aims to provide a way to set kernFlow from external packages as Go doesn't allow to acces to C struct from different packages.
Types ¶
type ApplicationPortMap ¶ added in v0.18.0
ApplicationPortMap maps UDP and TCP port numbers to service names
func NewApplicationPortMapFromConfig ¶ added in v0.18.0
func NewApplicationPortMapFromConfig() *ApplicationPortMap
NewApplicationPortMapFromConfig returns a new application port mapper and load it from the configuration file
type BPF ¶ added in v0.10.0
type BPF struct {
// contains filtered or unexported fields
}
BPF describes a filter
type EBPFFlow ¶ added in v0.24.0
EBPFFlow Wrapper type used for passing flows from probe to main agent routine
type ExtFlow ¶ added in v0.26.0
type ExtFlow struct { Type ExtFlowType Obj interface{} }
ExtFlow structure use to send external flow to the flow table
type ExtraLayers ¶ added in v0.21.0
type ExtraLayers int
ExtraLayers defines extra layer to be pushed in flow
const ( // VRRPLayer extra layer VRRPLayer ExtraLayers = 1 // DNSLayer extra layer DNSLayer ExtraLayers = 2 // DHCPv4Layer extra layer DHCPv4Layer ExtraLayers = 4 // ALLLayer all extra layers ALLLayer ExtraLayers = 255 )
func (ExtraLayers) Extract ¶ added in v0.21.0
func (e ExtraLayers) Extract() []string
Extract returns a string list of the ExtraLayers protocol
func (ExtraLayers) MarshalJSON ¶ added in v0.21.0
func (e ExtraLayers) MarshalJSON() ([]byte, error)
MarshalJSON serializes the ExtraLayers structure
func (*ExtraLayers) Parse ¶ added in v0.21.0
func (e *ExtraLayers) Parse(s ...string) error
Parse set the ExtraLayers struct with the given list of protocol strings
func (ExtraLayers) String ¶ added in v0.21.0
func (e ExtraLayers) String() string
String returns a string of the list of the protocols
func (*ExtraLayers) UnmarshalJSON ¶ added in v0.21.0
func (e *ExtraLayers) UnmarshalJSON(data []byte) error
UnmarshalJSON deserializes json input to ExtraLayers
type Flow ¶
type Flow struct { XXX_state flowState `json:"-"` // Flow Universally Unique IDentifier //flow.UUID is unique in the universe, as it should be used as a key of an //hashtable. By design 2 different flows, their UUID are always different. //flow.UUID can be used as Database Index. UUID string `protobuf:"bytes,1,opt,name=UUID,proto3" json:"UUID,omitempty"` LayersPath string `protobuf:"bytes,2,opt,name=LayersPath,proto3" json:"LayersPath,omitempty"` // Application is the last layer which is not a payload. Application string `protobuf:"bytes,3,opt,name=Application,proto3" json:"Application,omitempty"` // Data Flow info Link *FlowLayer `protobuf:"bytes,20,opt,name=Link,proto3" json:"Link,omitempty"` Network *FlowLayer `protobuf:"bytes,21,opt,name=Network,proto3" json:"Network,omitempty"` Transport *TransportLayer `protobuf:"bytes,22,opt,name=Transport,proto3" json:"Transport,omitempty"` ICMP *ICMPLayer `protobuf:"bytes,23,opt,name=ICMP,proto3" json:"ICMP,omitempty"` // extra layers DHCPv4 *layers.DHCPv4 `protobuf:"bytes,1000,opt,name=DHCPv4,proto3" json:"DHCPv4,omitempty"` DNS *layers.DNS `protobuf:"bytes,1001,opt,name=DNS,proto3" json:"DNS,omitempty"` VRRPv2 *layers.VRRPv2 `protobuf:"bytes,1002,opt,name=VRRPv2,proto3" json:"VRRPv2,omitempty"` // Data Flow Metric info from the 1st layer //amount of data between two updates LastUpdateMetric *FlowMetric `protobuf:"bytes,31,opt,name=LastUpdateMetric,proto3" json:"LastUpdateMetric,omitempty"` // Total amount of data for the whole flow duration Metric *FlowMetric `protobuf:"bytes,32,opt,name=Metric,proto3" json:"Metric,omitempty"` // Metric specific to the TCP and IPs Protocols and optional TCPMetric *TCPMetric `protobuf:"bytes,38,opt,name=TCPMetric,proto3" json:"TCPMetric,omitempty"` IPMetric *IPMetric `protobuf:"bytes,39,opt,name=IPMetric,proto3" json:"IPMetric,omitempty"` Start int64 `protobuf:"varint,10,opt,name=Start,proto3" json:"Start"` Last int64 `protobuf:"varint,11,opt,name=Last,proto3" json:"Last"` // Flow Tracking IDentifier, from 1st packet bytes //flow.TrackingID could be used to identify an unique flow whatever it has //been captured on the infrastructure. flow.TrackingID is calculated from //the bytes of the first packet of his session. //flow.TrackingID can be used as a Tag. TrackingID string `protobuf:"bytes,50,opt,name=TrackingID,proto3" json:"TrackingID,omitempty"` L3TrackingID string `protobuf:"bytes,51,opt,name=L3TrackingID,proto3" json:"L3TrackingID,omitempty"` // Flow Parent UUID is used as reference to the parent flow //Flow.ParentUUID is the same value that point to his parent flow.UUID ParentUUID string `protobuf:"bytes,6,opt,name=ParentUUID,proto3" json:"ParentUUID"` // Topology info NodeTID string `protobuf:"bytes,33,opt,name=NodeTID,proto3" json:"NodeTID,omitempty"` // Capture info CaptureID string `protobuf:"bytes,34,opt,name=CaptureID,proto3" json:"CaptureID,omitempty"` // raw packets, will not be exported, see Makefile LastRawPackets []*RawPacket `protobuf:"bytes,36,rep,name=LastRawPackets,proto3" json:"-"` // number of raw packet captured RawPacketsCaptured int64 `protobuf:"varint,37,opt,name=RawPacketsCaptured,proto3" json:"RawPacketsCaptured"` // describes the way the flow was ended (e.g. by RST, FIN) FinishType FlowFinishType `protobuf:"varint,60,opt,name=FinishType,proto3,enum=flow.FlowFinishType" json:"FinishType,omitempty"` }
func NewFlowFromGoPacket ¶ added in v0.26.0
NewFlowFromGoPacket creates a new flow from the given gopacket
func (*Flow) Descriptor ¶
func (*Flow) GetApplication ¶ added in v0.26.0
func (*Flow) GetCaptureID ¶ added in v0.26.0
func (*Flow) GetFieldBool ¶ added in v0.26.0
GetFieldBool returns the value of a boolean flow field
func (*Flow) GetFieldInt64 ¶ added in v0.7.0
GetFieldInt64 returns the value of a Flow field
func (*Flow) GetFieldKeys ¶ added in v0.26.0
GetFieldKeys returns the list of valid field of a Flow
func (*Flow) GetFieldString ¶ added in v0.7.0
GetFieldString returns the value of a Flow field
func (*Flow) GetFinishType ¶ added in v0.26.0
func (m *Flow) GetFinishType() FlowFinishType
func (*Flow) GetIPMetric ¶ added in v0.26.0
func (*Flow) GetL3TrackingID ¶ added in v0.26.0
func (*Flow) GetLastRawPackets ¶ added in v0.26.0
func (*Flow) GetLastUpdateMetric ¶ added in v0.7.0
func (m *Flow) GetLastUpdateMetric() *FlowMetric
func (*Flow) GetLayersPath ¶ added in v0.26.0
func (*Flow) GetMetric ¶ added in v0.7.0
func (m *Flow) GetMetric() *FlowMetric
func (*Flow) GetNetwork ¶ added in v0.7.0
func (*Flow) GetNodeTID ¶ added in v0.26.0
func (*Flow) GetParentUUID ¶ added in v0.26.0
func (*Flow) GetRawPacketsCaptured ¶ added in v0.26.0
func (*Flow) GetTCPMetric ¶ added in v0.26.0
func (*Flow) GetTrackingID ¶ added in v0.26.0
func (*Flow) GetTransport ¶ added in v0.7.0
func (m *Flow) GetTransport() *TransportLayer
func (*Flow) Init ¶ added in v0.7.0
Init initializes the flow with the given Timestamp, parentUUID and table uuids
func (*Flow) LinkType ¶ added in v0.26.0
LinkType returns the Link type of the flow according the its first available layer.
func (Flow) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (Flow) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*Flow) MarshalToSizedBuffer ¶ added in v0.26.0
func (*Flow) MatchBool ¶ added in v0.26.0
func (f *Flow) MatchBool(key string, predicate getter.BoolPredicate) bool
MatchBool implements the Getter interface
func (*Flow) MatchInt64 ¶ added in v0.26.0
func (f *Flow) MatchInt64(key string, predicate getter.Int64Predicate) bool
MatchInt64 implements the Getter interface
func (*Flow) MatchString ¶ added in v0.26.0
func (f *Flow) MatchString(key string, predicate getter.StringPredicate) bool
MatchString implements the Getter interface
func (*Flow) ProtoMessage ¶
func (*Flow) ProtoMessage()
func (*Flow) SetUUIDs ¶ added in v0.26.0
SetUUIDs updates the UUIDs using the flow layers and returns l2/l3 keys
func (*Flow) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*Flow) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*Flow) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *Flow) XXX_DiscardUnknown()
func (*Flow) XXX_Marshal ¶ added in v0.26.0
func (*Flow) XXX_Unmarshal ¶ added in v0.26.0
type FlowFinishType ¶ added in v0.26.0
type FlowFinishType int32
const ( FlowFinishType_NOT_FINISHED FlowFinishType = 0 FlowFinishType_TIMEOUT FlowFinishType = 1 FlowFinishType_TCP_FIN FlowFinishType = 2 FlowFinishType_TCP_RST FlowFinishType = 3 )
func (FlowFinishType) EnumDescriptor ¶ added in v0.26.0
func (FlowFinishType) EnumDescriptor() ([]byte, []int)
func (FlowFinishType) String ¶ added in v0.26.0
func (x FlowFinishType) String() string
type FlowLayer ¶ added in v0.7.0
type FlowLayer struct { Protocol FlowProtocol `protobuf:"varint,1,opt,name=Protocol,proto3,enum=flow.FlowProtocol" json:"Protocol"` A string `protobuf:"bytes,3,opt,name=A,proto3" json:"A,omitempty"` B string `protobuf:"bytes,4,opt,name=B,proto3" json:"B,omitempty"` ID int64 `protobuf:"varint,5,opt,name=ID,proto3" json:"ID"` }
gendecoder
func (*FlowLayer) Descriptor ¶ added in v0.7.0
func (*FlowLayer) GetFieldBool ¶ added in v0.26.0
func (*FlowLayer) GetFieldInt64 ¶ added in v0.26.0
func (*FlowLayer) GetFieldKeys ¶ added in v0.26.0
func (*FlowLayer) GetFieldString ¶ added in v0.26.0
func (*FlowLayer) GetProtocol ¶ added in v0.26.0
func (m *FlowLayer) GetProtocol() FlowProtocol
func (FlowLayer) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (FlowLayer) MarshalJSON ¶ added in v0.7.0
MarshalJSON supports json.Marshaler interface
func (*FlowLayer) MarshalToSizedBuffer ¶ added in v0.26.0
func (*FlowLayer) MatchBool ¶ added in v0.26.0
func (obj *FlowLayer) MatchBool(key string, predicate getter.BoolPredicate) bool
func (*FlowLayer) MatchInt64 ¶ added in v0.26.0
func (obj *FlowLayer) MatchInt64(key string, predicate getter.Int64Predicate) bool
func (*FlowLayer) MatchString ¶ added in v0.26.0
func (obj *FlowLayer) MatchString(key string, predicate getter.StringPredicate) bool
func (*FlowLayer) ProtoMessage ¶ added in v0.7.0
func (*FlowLayer) ProtoMessage()
func (*FlowLayer) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*FlowLayer) UnmarshalJSON ¶ added in v0.7.0
UnmarshalJSON supports json.Unmarshaler interface
func (*FlowLayer) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *FlowLayer) XXX_DiscardUnknown()
func (*FlowLayer) XXX_Marshal ¶ added in v0.26.0
func (*FlowLayer) XXX_Unmarshal ¶ added in v0.26.0
type FlowMetric ¶ added in v0.7.0
type FlowMetric struct { ABPackets int64 `protobuf:"varint,2,opt,name=ABPackets,proto3" json:"ABPackets"` ABBytes int64 `protobuf:"varint,3,opt,name=ABBytes,proto3" json:"ABBytes"` BAPackets int64 `protobuf:"varint,4,opt,name=BAPackets,proto3" json:"BAPackets"` BABytes int64 `protobuf:"varint,5,opt,name=BABytes,proto3" json:"BABytes"` Start int64 `protobuf:"varint,6,opt,name=Start,proto3" json:"Start"` Last int64 `protobuf:"varint,7,opt,name=Last,proto3" json:"Last"` RTT int64 `protobuf:"varint,8,opt,name=RTT,proto3" json:"RTT,omitempty"` }
gendecoder
func (*FlowMetric) Add ¶ added in v0.26.0
func (fm *FlowMetric) Add(m common.Metric) common.Metric
Add sum flow metrics
func (*FlowMetric) Descriptor ¶ added in v0.7.0
func (*FlowMetric) Descriptor() ([]byte, []int)
func (*FlowMetric) GetABBytes ¶ added in v0.26.0
func (m *FlowMetric) GetABBytes() int64
func (*FlowMetric) GetABPackets ¶ added in v0.26.0
func (m *FlowMetric) GetABPackets() int64
func (*FlowMetric) GetBABytes ¶ added in v0.26.0
func (m *FlowMetric) GetBABytes() int64
func (*FlowMetric) GetBAPackets ¶ added in v0.26.0
func (m *FlowMetric) GetBAPackets() int64
func (*FlowMetric) GetField ¶ added in v0.7.0
func (obj *FlowMetric) GetField(key string) (interface{}, error)
func (*FlowMetric) GetFieldBool ¶ added in v0.26.0
func (obj *FlowMetric) GetFieldBool(key string) (bool, error)
func (*FlowMetric) GetFieldInt64 ¶ added in v0.26.0
func (obj *FlowMetric) GetFieldInt64(key string) (int64, error)
func (*FlowMetric) GetFieldKeys ¶ added in v0.26.0
func (obj *FlowMetric) GetFieldKeys() []string
func (*FlowMetric) GetFieldString ¶ added in v0.26.0
func (obj *FlowMetric) GetFieldString(key string) (string, error)
func (*FlowMetric) GetLast ¶ added in v0.26.0
func (m *FlowMetric) GetLast() int64
func (*FlowMetric) GetRTT ¶ added in v0.26.0
func (m *FlowMetric) GetRTT() int64
func (*FlowMetric) GetStart ¶ added in v0.26.0
func (m *FlowMetric) GetStart() int64
func (*FlowMetric) IsZero ¶ added in v0.26.0
func (fm *FlowMetric) IsZero() bool
IsZero returns true if all the values are equal to zero
func (*FlowMetric) Marshal ¶ added in v0.26.0
func (m *FlowMetric) Marshal() (dAtA []byte, err error)
func (FlowMetric) MarshalEasyJSON ¶ added in v0.26.0
func (v FlowMetric) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (FlowMetric) MarshalJSON ¶ added in v0.26.0
func (v FlowMetric) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*FlowMetric) MarshalTo ¶ added in v0.26.0
func (m *FlowMetric) MarshalTo(dAtA []byte) (int, error)
func (*FlowMetric) MarshalToSizedBuffer ¶ added in v0.26.0
func (m *FlowMetric) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*FlowMetric) MatchBool ¶ added in v0.26.0
func (obj *FlowMetric) MatchBool(key string, predicate getter.BoolPredicate) bool
func (*FlowMetric) MatchInt64 ¶ added in v0.26.0
func (obj *FlowMetric) MatchInt64(key string, predicate getter.Int64Predicate) bool
func (*FlowMetric) MatchString ¶ added in v0.26.0
func (obj *FlowMetric) MatchString(key string, predicate getter.StringPredicate) bool
func (*FlowMetric) ProtoMessage ¶ added in v0.7.0
func (*FlowMetric) ProtoMessage()
func (*FlowMetric) ProtoSize ¶ added in v0.26.0
func (m *FlowMetric) ProtoSize() (n int)
func (*FlowMetric) Reset ¶ added in v0.7.0
func (m *FlowMetric) Reset()
func (*FlowMetric) SetLast ¶ added in v0.26.0
func (fm *FlowMetric) SetLast(last int64)
SetLast set Last field
func (*FlowMetric) SetStart ¶ added in v0.26.0
func (fm *FlowMetric) SetStart(start int64)
SetStart set Start field
func (*FlowMetric) String ¶ added in v0.7.0
func (m *FlowMetric) String() string
func (*FlowMetric) Sub ¶ added in v0.26.0
func (fm *FlowMetric) Sub(m common.Metric) common.Metric
Sub subtracts flow metrics
func (*FlowMetric) Unmarshal ¶ added in v0.26.0
func (m *FlowMetric) Unmarshal(dAtA []byte) error
func (*FlowMetric) UnmarshalEasyJSON ¶ added in v0.26.0
func (v *FlowMetric) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*FlowMetric) UnmarshalJSON ¶ added in v0.26.0
func (v *FlowMetric) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
func (*FlowMetric) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *FlowMetric) XXX_DiscardUnknown()
func (*FlowMetric) XXX_Marshal ¶ added in v0.26.0
func (m *FlowMetric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*FlowMetric) XXX_Merge ¶ added in v0.26.0
func (m *FlowMetric) XXX_Merge(src proto.Message)
func (*FlowMetric) XXX_Size ¶ added in v0.26.0
func (m *FlowMetric) XXX_Size() int
func (*FlowMetric) XXX_Unmarshal ¶ added in v0.26.0
func (m *FlowMetric) XXX_Unmarshal(b []byte) error
type FlowProtocol ¶ added in v0.7.0
type FlowProtocol int32
const ( FlowProtocol_ETHERNET FlowProtocol = 0 FlowProtocol_IPV4 FlowProtocol = 1 FlowProtocol_TCP FlowProtocol = 2 FlowProtocol_UDP FlowProtocol = 3 FlowProtocol_SCTP FlowProtocol = 4 FlowProtocol_IPV6 FlowProtocol = 5 FlowProtocol_ICMPV4 FlowProtocol = 6 FlowProtocol_ICMPV6 FlowProtocol = 7 )
func (FlowProtocol) EnumDescriptor ¶ added in v0.7.0
func (FlowProtocol) EnumDescriptor() ([]byte, []int)
func (FlowProtocol) MarshalJSON ¶ added in v0.26.0
func (p FlowProtocol) MarshalJSON() ([]byte, error)
MarshalJSON serialize a FlowProtocol in JSON
func (FlowProtocol) String ¶ added in v0.7.0
func (x FlowProtocol) String() string
func (*FlowProtocol) UnmarshalJSON ¶ added in v0.26.0
func (p *FlowProtocol) UnmarshalJSON(b []byte) error
UnmarshalJSON serialize a FlowProtocol in JSON
func (FlowProtocol) Value ¶ added in v0.7.0
func (p FlowProtocol) Value() int32
Value returns int32 value of a FlowProtocol
type FlowSearchReply ¶ added in v0.4.0
type FlowSearchReply struct {
FlowSet *FlowSet `protobuf:"bytes,1,opt,name=FlowSet,proto3" json:"FlowSet,omitempty"`
}
func (*FlowSearchReply) Descriptor ¶ added in v0.5.0
func (*FlowSearchReply) Descriptor() ([]byte, []int)
func (*FlowSearchReply) GetFlowSet ¶ added in v0.5.0
func (m *FlowSearchReply) GetFlowSet() *FlowSet
func (*FlowSearchReply) Marshal ¶ added in v0.26.0
func (m *FlowSearchReply) Marshal() (dAtA []byte, err error)
func (FlowSearchReply) MarshalEasyJSON ¶ added in v0.26.0
func (v FlowSearchReply) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (FlowSearchReply) MarshalJSON ¶ added in v0.26.0
func (v FlowSearchReply) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*FlowSearchReply) MarshalTo ¶ added in v0.26.0
func (m *FlowSearchReply) MarshalTo(dAtA []byte) (int, error)
func (*FlowSearchReply) MarshalToSizedBuffer ¶ added in v0.26.0
func (m *FlowSearchReply) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*FlowSearchReply) ProtoMessage ¶ added in v0.5.0
func (*FlowSearchReply) ProtoMessage()
func (*FlowSearchReply) ProtoSize ¶ added in v0.26.0
func (m *FlowSearchReply) ProtoSize() (n int)
func (*FlowSearchReply) Reset ¶ added in v0.5.0
func (m *FlowSearchReply) Reset()
func (*FlowSearchReply) String ¶ added in v0.5.0
func (m *FlowSearchReply) String() string
func (*FlowSearchReply) Unmarshal ¶ added in v0.26.0
func (m *FlowSearchReply) Unmarshal(dAtA []byte) error
func (*FlowSearchReply) UnmarshalEasyJSON ¶ added in v0.26.0
func (v *FlowSearchReply) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*FlowSearchReply) UnmarshalJSON ¶ added in v0.26.0
func (v *FlowSearchReply) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
func (*FlowSearchReply) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *FlowSearchReply) XXX_DiscardUnknown()
func (*FlowSearchReply) XXX_Marshal ¶ added in v0.26.0
func (m *FlowSearchReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*FlowSearchReply) XXX_Merge ¶ added in v0.26.0
func (m *FlowSearchReply) XXX_Merge(src proto.Message)
func (*FlowSearchReply) XXX_Size ¶ added in v0.26.0
func (m *FlowSearchReply) XXX_Size() int
func (*FlowSearchReply) XXX_Unmarshal ¶ added in v0.26.0
func (m *FlowSearchReply) XXX_Unmarshal(b []byte) error
type FlowSet ¶ added in v0.4.0
type FlowSet struct { Flows []*Flow `protobuf:"bytes,1,rep,name=Flows,proto3" json:"Flows,omitempty"` Start int64 `protobuf:"varint,2,opt,name=Start,proto3" json:"Start"` End int64 `protobuf:"varint,3,opt,name=End,proto3" json:"End"` }
func (*FlowSet) Descriptor ¶ added in v0.5.0
func (FlowSet) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (FlowSet) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*FlowSet) MarshalToSizedBuffer ¶ added in v0.26.0
func (*FlowSet) Merge ¶ added in v0.4.0
func (fs *FlowSet) Merge(ofs *FlowSet, context MergeContext) error
Merge merges two FlowSet. If Sorted both of the FlowSet have to be sorted first. If Dedup both of the FlowSet have to be dedup first too.
func (*FlowSet) ProtoMessage ¶ added in v0.5.0
func (*FlowSet) ProtoMessage()
func (*FlowSet) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*FlowSet) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*FlowSet) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *FlowSet) XXX_DiscardUnknown()
func (*FlowSet) XXX_Marshal ¶ added in v0.26.0
func (*FlowSet) XXX_Unmarshal ¶ added in v0.26.0
type ICMPLayer ¶ added in v0.26.0
type ICMPLayer struct { Type ICMPType `protobuf:"varint,1,opt,name=Type,proto3,enum=flow.ICMPType" json:"Type"` Code uint32 `protobuf:"varint,2,opt,name=Code,proto3" json:"Code,omitempty"` ID uint32 `protobuf:"varint,3,opt,name=ID,proto3" json:"ID,omitempty"` }
gendecoder
func (*ICMPLayer) Descriptor ¶ added in v0.26.0
func (*ICMPLayer) GetFieldBool ¶ added in v0.26.0
func (*ICMPLayer) GetFieldInt64 ¶ added in v0.26.0
func (*ICMPLayer) GetFieldKeys ¶ added in v0.26.0
func (*ICMPLayer) GetFieldString ¶ added in v0.26.0
func (ICMPLayer) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (ICMPLayer) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*ICMPLayer) MarshalToSizedBuffer ¶ added in v0.26.0
func (*ICMPLayer) MatchBool ¶ added in v0.26.0
func (obj *ICMPLayer) MatchBool(key string, predicate getter.BoolPredicate) bool
func (*ICMPLayer) MatchInt64 ¶ added in v0.26.0
func (obj *ICMPLayer) MatchInt64(key string, predicate getter.Int64Predicate) bool
func (*ICMPLayer) MatchString ¶ added in v0.26.0
func (obj *ICMPLayer) MatchString(key string, predicate getter.StringPredicate) bool
func (*ICMPLayer) ProtoMessage ¶ added in v0.26.0
func (*ICMPLayer) ProtoMessage()
func (*ICMPLayer) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*ICMPLayer) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*ICMPLayer) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *ICMPLayer) XXX_DiscardUnknown()
func (*ICMPLayer) XXX_Marshal ¶ added in v0.26.0
func (*ICMPLayer) XXX_Unmarshal ¶ added in v0.26.0
type ICMPType ¶ added in v0.26.0
type ICMPType int32
const ( ICMPType_UNKNOWN ICMPType = 0 ICMPType_DESTINATION_UNREACHABLE ICMPType = 1 ICMPType_ECHO ICMPType = 2 ICMPType_NEIGHBOR ICMPType = 3 ICMPType_ADDRESS_MASK ICMPType = 4 ICMPType_INFO ICMPType = 5 ICMPType_PARAMETER_PROBLEM ICMPType = 6 ICMPType_REDIRECT ICMPType = 7 ICMPType_ROUTER ICMPType = 8 ICMPType_SOURCE_QUENCH ICMPType = 9 ICMPType_TIME_EXCEEDED ICMPType = 10 ICMPType_TIMESTAMP ICMPType = 11 ICMPType_PACKET_TOO_BIG ICMPType = 12 )
func ICMPv4TypeToFlowICMPType ¶ added in v0.26.0
ICMPv4TypeToFlowICMPType converts an ICMP type to a Flow ICMPType
func ICMPv6TypeToFlowICMPType ¶ added in v0.26.0
ICMPv6TypeToFlowICMPType converts an ICMP type to a Flow ICMPType
func (ICMPType) EnumDescriptor ¶ added in v0.26.0
func (ICMPType) MarshalJSON ¶ added in v0.26.0
MarshalJSON serialize a FlowProtocol in JSON
func (*ICMPType) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON serialize a ICMPType in JSON
type ICMPv4 ¶ added in v0.12.0
ICMPv4 aims to store ICMP metadata and aims to be used for the flow hash key
type ICMPv6 ¶ added in v0.12.0
ICMPv6 aims to store ICMP metadata and aims to be used for the flow hash key
type IPDefragger ¶ added in v0.18.0
type IPDefragger struct { insanelock.RWMutex // contains filtered or unexported fields }
IPDefragger defines an IPv4 defragmenter
func NewIPDefragger ¶ added in v0.18.0
func NewIPDefragger() *IPDefragger
NewIPDefragger returns a new IPv4 defragger
func (*IPDefragger) Defrag ¶ added in v0.18.0
func (d *IPDefragger) Defrag(packet gopacket.Packet) (*IPMetric, bool)
Defrag tries to defragment
func (*IPDefragger) FlushAll ¶ added in v0.18.0
func (d *IPDefragger) FlushAll()
FlushAll frees all the fragment resources
func (*IPDefragger) FlushOlderThan ¶ added in v0.18.0
func (d *IPDefragger) FlushOlderThan(t time.Time)
FlushOlderThan frees resources for fragment older than the give time
type IPDefraggerMetric ¶ added in v0.18.0
type IPDefraggerMetric struct {
// contains filtered or unexported fields
}
IPDefraggerMetric defines the structure keeping metrics of fragments
type IPMetric ¶ added in v0.26.0
type IPMetric struct { Fragments int64 `protobuf:"varint,1,opt,name=Fragments,proto3" json:"Fragments"` FragmentErrors int64 `protobuf:"varint,2,opt,name=FragmentErrors,proto3" json:"FragmentErrors"` }
gendecoder
func ProcessGoPacket ¶ added in v0.26.0
func ProcessGoPacket(packet gopacket.Packet, bpf *BPF, defragger *IPDefragger) (gopacket.Packet, *IPMetric)
ProcessGoPacket takes a gopacket as input and filter, defrag it.
func (*IPMetric) Descriptor ¶ added in v0.26.0
func (*IPMetric) GetFieldBool ¶ added in v0.26.0
func (*IPMetric) GetFieldInt64 ¶ added in v0.26.0
func (*IPMetric) GetFieldKeys ¶ added in v0.26.0
func (*IPMetric) GetFieldString ¶ added in v0.26.0
func (*IPMetric) GetFragmentErrors ¶ added in v0.26.0
func (*IPMetric) GetFragments ¶ added in v0.26.0
func (IPMetric) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (IPMetric) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*IPMetric) MarshalToSizedBuffer ¶ added in v0.26.0
func (*IPMetric) MatchBool ¶ added in v0.26.0
func (obj *IPMetric) MatchBool(key string, predicate getter.BoolPredicate) bool
func (*IPMetric) MatchInt64 ¶ added in v0.26.0
func (obj *IPMetric) MatchInt64(key string, predicate getter.Int64Predicate) bool
func (*IPMetric) MatchString ¶ added in v0.26.0
func (obj *IPMetric) MatchString(key string, predicate getter.StringPredicate) bool
func (*IPMetric) ProtoMessage ¶ added in v0.26.0
func (*IPMetric) ProtoMessage()
func (*IPMetric) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*IPMetric) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*IPMetric) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *IPMetric) XXX_DiscardUnknown()
func (*IPMetric) XXX_Marshal ¶ added in v0.26.0
func (*IPMetric) XXX_Unmarshal ¶ added in v0.26.0
type LayerKeyMode ¶ added in v0.18.0
type LayerKeyMode int
LayerKeyMode defines what are the layers used for the flow key calculation
const ( DefaultLayerKeyMode = L2KeyMode // default mode L2KeyMode LayerKeyMode = 0 // uses Layer2 and Layer3 for hash computation, default mode L3PreferredKeyMode LayerKeyMode = 1 // uses Layer3 only and layer2 if no Layer3 )
Flow key calculation modes
func LayerKeyModeByName ¶ added in v0.18.0
func LayerKeyModeByName(name string) (LayerKeyMode, error)
LayerKeyModeByName converts a string to a layer key mode
func (LayerKeyMode) String ¶ added in v0.18.0
func (l LayerKeyMode) String() string
type MergeContext ¶ added in v0.7.0
type MergeContext struct { Sort bool SortBy string SortOrder filters.SortOrder Dedup bool DedupBy string }
MergeContext describes a mechanism to merge flow sets
type Message ¶ added in v0.26.0
type Message struct { Flows []*Flow `protobuf:"bytes,1,rep,name=Flows,proto3" json:"Flows,omitempty"` Stats *Stats `protobuf:"bytes,2,opt,name=Stats,proto3" json:"Stats,omitempty"` }
func (*Message) Descriptor ¶ added in v0.26.0
func (Message) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (Message) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*Message) MarshalToSizedBuffer ¶ added in v0.26.0
func (*Message) ProtoMessage ¶ added in v0.26.0
func (*Message) ProtoMessage()
func (*Message) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*Message) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*Message) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *Message) XXX_DiscardUnknown()
func (*Message) XXX_Marshal ¶ added in v0.26.0
func (*Message) XXX_Unmarshal ¶ added in v0.26.0
type Operation ¶ added in v0.22.0
type Operation struct { Key uint64 Flow *Flow Type OperationType }
Operation describes a flow operation
type OperationType ¶ added in v0.22.0
type OperationType int
OperationType operation type of a Flow in a flow table
const ( // ReplaceOperation replace the flow ReplaceOperation OperationType = iota // UpdateOperation update the flow UpdateOperation )
type Opts ¶ added in v0.21.0
type Opts struct { TCPMetric bool IPDefrag bool LayerKeyMode LayerKeyMode AppPortMap *ApplicationPortMap ExtraLayers ExtraLayers }
Opts describes options that can be used to process flows
type Packet ¶ added in v0.12.0
type Packet struct { GoPacket gopacket.Packet // orignal gopacket Layers []gopacket.Layer // layer of the sub packet Data []byte // byte of the sub packet Length int64 // length of the original packet meaning layers + payload IPMetric *IPMetric // contains filtered or unexported fields }
Packet describes one packet
func (*Packet) ApplicationFlow ¶ added in v0.18.0
ApplicationFlow returns first application flow
func (*Packet) NetworkLayer ¶ added in v0.18.0
func (p *Packet) NetworkLayer() gopacket.NetworkLayer
NetworkLayer return first network layer
func (*Packet) TransportFlow ¶ added in v0.18.0
TransportFlow returns first transport flow
func (*Packet) TransportLayer ¶ added in v0.18.0
func (p *Packet) TransportLayer() gopacket.TransportLayer
TransportLayer returns first transport layer
type PacketSequence ¶ added in v0.15.0
type PacketSequence struct {
Packets []*Packet
}
PacketSequence represents a suite of parent/child Packet
func PacketSeqFromGoPacket ¶ added in v0.15.0
func PacketSeqFromGoPacket(packet gopacket.Packet, outerLength int64, bpf *BPF, defragger *IPDefragger) *PacketSequence
PacketSeqFromGoPacket split original packet into multiple packets in case of encapsulation like GRE, VXLAN, etc.
func PacketSeqFromSFlowSample ¶ added in v0.15.0
func PacketSeqFromSFlowSample(sample *layers.SFlowFlowSample, bpf *BPF, defragger *IPDefragger) []*PacketSequence
PacketSeqFromSFlowSample returns an array of Packets as a sample contains multiple records which generate a Packets each.
type PcapTableFeeder ¶ added in v0.12.0
PcapTableFeeder replaies a pcap file
func NewPcapTableFeeder ¶ added in v0.12.0
func NewPcapTableFeeder(r io.ReadCloser, packetsChan chan *PacketSequence, replay bool, bpfFilter string) (*PcapTableFeeder, error)
NewPcapTableFeeder reads a pcap from a file reader and inject it in a flow table
func (*PcapTableFeeder) Start ¶ added in v0.12.0
func (p *PcapTableFeeder) Start()
Start a pcap injector
func (*PcapTableFeeder) Stop ¶ added in v0.12.0
func (p *PcapTableFeeder) Stop()
Stop a pcap injector
type PcapWriter ¶ added in v0.10.0
type PcapWriter struct {
// contains filtered or unexported fields
}
PcapWriter provides helpers on top of gopacket pcap to write pcap files.
func NewPcapWriter ¶ added in v0.10.0
func NewPcapWriter(w io.Writer) *PcapWriter
NewPcapWriter returns a new PcapWriter based on the given io.Writer. Due to the current limitation of the gopacket pcap implementation only RawPacket with Ethernet link type are supported.
func (*PcapWriter) WriteRawPacket ¶ added in v0.12.0
func (p *PcapWriter) WriteRawPacket(r *RawPacket) error
WriteRawPacket writes a RawPacket
func (*PcapWriter) WriteRawPackets ¶ added in v0.12.0
func (p *PcapWriter) WriteRawPackets(fr []*RawPacket) error
WriteRawPackets writes a RawPackets iterating over the RawPackets and using WriteRawPacket for each.
type RawPacket ¶ added in v0.26.0
type RawPacket struct { Timestamp int64 `protobuf:"varint,1,opt,name=Timestamp,proto3" json:"Timestamp"` Index int64 `protobuf:"varint,2,opt,name=Index,proto3" json:"Index"` Data []byte `protobuf:"bytes,3,opt,name=Data,proto3" json:"Data,omitempty"` LinkType github_com_google_gopacket_layers.LinkType `protobuf:"varint,4,opt,name=LinkType,proto3,casttype=github.com/google/gopacket/layers.LinkType" json:"LinkType,omitempty"` }
func (*RawPacket) Descriptor ¶ added in v0.26.0
func (*RawPacket) GetLinkType ¶ added in v0.26.0
func (m *RawPacket) GetLinkType() github_com_google_gopacket_layers.LinkType
func (*RawPacket) GetTimestamp ¶ added in v0.26.0
func (RawPacket) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (RawPacket) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*RawPacket) MarshalToSizedBuffer ¶ added in v0.26.0
func (*RawPacket) ProtoMessage ¶ added in v0.26.0
func (*RawPacket) ProtoMessage()
func (*RawPacket) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*RawPacket) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*RawPacket) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *RawPacket) XXX_DiscardUnknown()
func (*RawPacket) XXX_Marshal ¶ added in v0.26.0
func (*RawPacket) XXX_Unmarshal ¶ added in v0.26.0
type Stats ¶ added in v0.26.0
type Stats struct { CaptureID string `protobuf:"bytes,1,opt,name=CaptureID,proto3" json:"CaptureID,omitempty"` FlowCount int64 `protobuf:"varint,2,opt,name=FlowCount,proto3" json:"FlowCount"` FlowDropped int64 `protobuf:"varint,3,opt,name=FlowDropped,proto3" json:"FlowDropped"` KernelFlowDropped int64 `protobuf:"varint,4,opt,name=KernelFlowDropped,proto3" json:"KernelFlowDropped"` PacketsDropped int64 `protobuf:"varint,5,opt,name=PacketsDropped,proto3" json:"PacketsDropped"` PacketsReceived int64 `protobuf:"varint,6,opt,name=PacketsReceived,proto3" json:"PacketsReceived"` }
func (*Stats) Descriptor ¶ added in v0.26.0
func (*Stats) GetCaptureID ¶ added in v0.26.0
func (*Stats) GetFlowCount ¶ added in v0.26.0
func (*Stats) GetFlowDropped ¶ added in v0.26.0
func (*Stats) GetKernelFlowDropped ¶ added in v0.26.0
func (*Stats) GetPacketsDropped ¶ added in v0.26.0
func (*Stats) GetPacketsReceived ¶ added in v0.26.0
func (Stats) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (Stats) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*Stats) MarshalToSizedBuffer ¶ added in v0.26.0
func (*Stats) ProtoMessage ¶ added in v0.26.0
func (*Stats) ProtoMessage()
func (*Stats) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*Stats) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*Stats) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *Stats) XXX_DiscardUnknown()
func (*Stats) XXX_Marshal ¶ added in v0.26.0
func (*Stats) XXX_Unmarshal ¶ added in v0.26.0
type TCPAssembler ¶ added in v0.18.0
type TCPAssembler struct {
// contains filtered or unexported fields
}
TCPAssembler defines a tcp reassembler
func NewTCPAssembler ¶ added in v0.18.0
func NewTCPAssembler() *TCPAssembler
NewTCPAssembler returns a new TCPAssembler
func (*TCPAssembler) Assemble ¶ added in v0.18.0
func (t *TCPAssembler) Assemble(packet gopacket.Packet)
Assemble add a new packet to be reassembled
func (*TCPAssembler) FlushAll ¶ added in v0.18.0
func (t *TCPAssembler) FlushAll()
FlushAll frees all the resources
func (*TCPAssembler) FlushOlderThan ¶ added in v0.18.0
func (t *TCPAssembler) FlushOlderThan(tm time.Time)
FlushOlderThan frees the resources older than the given time
func (*TCPAssembler) New ¶ added in v0.18.0
func (t *TCPAssembler) New(network, transport gopacket.Flow) tcpassembly.Stream
New creates a new stream. It's called whenever the assembler sees a stream it isn't currently following.
func (*TCPAssembler) RegisterFlow ¶ added in v0.18.0
func (t *TCPAssembler) RegisterFlow(flow *Flow, packet gopacket.Packet)
RegisterFlow registers a new flow to be tracked
type TCPAssemblerStream ¶ added in v0.18.0
type TCPAssemblerStream struct {
// contains filtered or unexported fields
}
TCPAssemblerStream will handle the actual tcp stream decoding
func (*TCPAssemblerStream) Reassembled ¶ added in v0.18.0
func (s *TCPAssemblerStream) Reassembled(reassemblies []tcpassembly.Reassembly)
Reassembled is called whenever new packet data is available for reading. Reassembly objects contain stream data in received order.
func (*TCPAssemblerStream) ReassemblyComplete ¶ added in v0.18.0
func (s *TCPAssemblerStream) ReassemblyComplete()
ReassemblyComplete is called when the TCP assembler believes a stream has finished.
type TCPMetric ¶ added in v0.26.0
type TCPMetric struct { ABSynStart int64 `protobuf:"varint,1,opt,name=ABSynStart,proto3" json:"ABSynStart"` BASynStart int64 `protobuf:"varint,2,opt,name=BASynStart,proto3" json:"BASynStart"` ABSynTTL uint32 `protobuf:"varint,3,opt,name=ABSynTTL,proto3" json:"ABSynTTL,omitempty"` BASynTTL uint32 `protobuf:"varint,4,opt,name=BASynTTL,proto3" json:"BASynTTL,omitempty"` ABFinStart int64 `protobuf:"varint,5,opt,name=ABFinStart,proto3" json:"ABFinStart"` BAFinStart int64 `protobuf:"varint,6,opt,name=BAFinStart,proto3" json:"BAFinStart"` ABRstStart int64 `protobuf:"varint,7,opt,name=ABRstStart,proto3" json:"ABRstStart"` BARstStart int64 `protobuf:"varint,8,opt,name=BARstStart,proto3" json:"BARstStart"` ABSegmentOutOfOrder int64 `protobuf:"varint,9,opt,name=ABSegmentOutOfOrder,proto3" json:"ABSegmentOutOfOrder"` ABSegmentSkipped int64 `protobuf:"varint,10,opt,name=ABSegmentSkipped,proto3" json:"ABSegmentSkipped"` ABSegmentSkippedBytes int64 `protobuf:"varint,11,opt,name=ABSegmentSkippedBytes,proto3" json:"ABSegmentSkippedBytes"` ABPackets int64 `protobuf:"varint,12,opt,name=ABPackets,proto3" json:"ABPackets"` ABBytes int64 `protobuf:"varint,13,opt,name=ABBytes,proto3" json:"ABBytes"` ABSawStart int64 `protobuf:"varint,14,opt,name=ABSawStart,proto3" json:"ABSawStart"` ABSawEnd int64 `protobuf:"varint,15,opt,name=ABSawEnd,proto3" json:"ABSawEnd"` BASegmentOutOfOrder int64 `protobuf:"varint,16,opt,name=BASegmentOutOfOrder,proto3" json:"BASegmentOutOfOrder"` BASegmentSkipped int64 `protobuf:"varint,17,opt,name=BASegmentSkipped,proto3" json:"BASegmentSkipped"` BASegmentSkippedBytes int64 `protobuf:"varint,18,opt,name=BASegmentSkippedBytes,proto3" json:"BASegmentSkippedBytes"` BAPackets int64 `protobuf:"varint,19,opt,name=BAPackets,proto3" json:"BAPackets"` BABytes int64 `protobuf:"varint,20,opt,name=BABytes,proto3" json:"BABytes"` BASawStart int64 `protobuf:"varint,21,opt,name=BASawStart,proto3" json:"BASawStart"` BASawEnd int64 `protobuf:"varint,22,opt,name=BASawEnd,proto3" json:"BASawEnd"` }
gendecoder
func (*TCPMetric) Descriptor ¶ added in v0.26.0
func (*TCPMetric) GetABBytes ¶ added in v0.26.0
func (*TCPMetric) GetABFinStart ¶ added in v0.26.0
func (*TCPMetric) GetABPackets ¶ added in v0.26.0
func (*TCPMetric) GetABRstStart ¶ added in v0.26.0
func (*TCPMetric) GetABSawEnd ¶ added in v0.26.0
func (*TCPMetric) GetABSawStart ¶ added in v0.26.0
func (*TCPMetric) GetABSegmentOutOfOrder ¶ added in v0.26.0
func (*TCPMetric) GetABSegmentSkipped ¶ added in v0.26.0
func (*TCPMetric) GetABSegmentSkippedBytes ¶ added in v0.26.0
func (*TCPMetric) GetABSynStart ¶ added in v0.26.0
func (*TCPMetric) GetABSynTTL ¶ added in v0.26.0
func (*TCPMetric) GetBABytes ¶ added in v0.26.0
func (*TCPMetric) GetBAFinStart ¶ added in v0.26.0
func (*TCPMetric) GetBAPackets ¶ added in v0.26.0
func (*TCPMetric) GetBARstStart ¶ added in v0.26.0
func (*TCPMetric) GetBASawEnd ¶ added in v0.26.0
func (*TCPMetric) GetBASawStart ¶ added in v0.26.0
func (*TCPMetric) GetBASegmentOutOfOrder ¶ added in v0.26.0
func (*TCPMetric) GetBASegmentSkipped ¶ added in v0.26.0
func (*TCPMetric) GetBASegmentSkippedBytes ¶ added in v0.26.0
func (*TCPMetric) GetBASynStart ¶ added in v0.26.0
func (*TCPMetric) GetBASynTTL ¶ added in v0.26.0
func (*TCPMetric) GetFieldBool ¶ added in v0.26.0
func (*TCPMetric) GetFieldInt64 ¶ added in v0.26.0
func (*TCPMetric) GetFieldKeys ¶ added in v0.26.0
func (*TCPMetric) GetFieldString ¶ added in v0.26.0
func (TCPMetric) MarshalEasyJSON ¶ added in v0.26.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (TCPMetric) MarshalJSON ¶ added in v0.26.0
MarshalJSON supports json.Marshaler interface
func (*TCPMetric) MarshalToSizedBuffer ¶ added in v0.26.0
func (*TCPMetric) MatchBool ¶ added in v0.26.0
func (obj *TCPMetric) MatchBool(key string, predicate getter.BoolPredicate) bool
func (*TCPMetric) MatchInt64 ¶ added in v0.26.0
func (obj *TCPMetric) MatchInt64(key string, predicate getter.Int64Predicate) bool
func (*TCPMetric) MatchString ¶ added in v0.26.0
func (obj *TCPMetric) MatchString(key string, predicate getter.StringPredicate) bool
func (*TCPMetric) ProtoMessage ¶ added in v0.26.0
func (*TCPMetric) ProtoMessage()
func (*TCPMetric) UnmarshalEasyJSON ¶ added in v0.26.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*TCPMetric) UnmarshalJSON ¶ added in v0.26.0
UnmarshalJSON supports json.Unmarshaler interface
func (*TCPMetric) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *TCPMetric) XXX_DiscardUnknown()
func (*TCPMetric) XXX_Marshal ¶ added in v0.26.0
func (*TCPMetric) XXX_Unmarshal ¶ added in v0.26.0
type Table ¶ added in v0.4.0
type Table struct { Opts TableOpts // contains filtered or unexported fields }
Table store the flow table and related metrics mechanism
func NewTable ¶ added in v0.4.0
func NewTable(updateEvery, expireAfter time.Duration, sender Sender, uuids UUIDs, opts ...TableOpts) *Table
NewTable creates a new flow table
func (*Table) FeedWithGoPacket ¶ added in v0.18.0
FeedWithGoPacket feeds the table with a gopacket
func (*Table) FeedWithSFlowSample ¶ added in v0.18.0
func (ft *Table) FeedWithSFlowSample(sample *layers.SFlowFlowSample, bpf *BPF)
FeedWithSFlowSample feeds the table with sflow samples
func (*Table) IPDefragger ¶ added in v0.18.0
func (ft *Table) IPDefragger() *IPDefragger
IPDefragger returns the ipDefragger if enabled
func (*Table) Query ¶ added in v0.4.0
func (ft *Table) Query(query *TableQuery) []byte
Query a flow table
func (*Table) Run ¶ added in v0.7.0
func (ft *Table) Run()
Run background jobs, like update/expire entries event
func (*Table) Start ¶ added in v0.4.0
func (ft *Table) Start(extFlowExp chan interface{}) (chan *PacketSequence, chan *ExtFlow, chan Stats)
Start the flow table
type TableAllocator ¶ added in v0.4.0
type TableAllocator struct { insanelock.RWMutex // contains filtered or unexported fields }
TableAllocator aims to create/allocate a new flow table
func NewTableAllocator ¶ added in v0.4.0
func NewTableAllocator(updateEvery, expireAfter time.Duration, sender Sender) *TableAllocator
NewTableAllocator creates a new flow table
func (*TableAllocator) Alloc ¶ added in v0.4.0
func (a *TableAllocator) Alloc(uuids UUIDs, opts TableOpts) *Table
Alloc instantiate/allocate a new table
func (*TableAllocator) ExpireAfter ¶ added in v0.24.0
func (a *TableAllocator) ExpireAfter() time.Duration
ExpireAfter returns the expiration duration
func (*TableAllocator) QueryTable ¶ added in v0.4.0
func (a *TableAllocator) QueryTable(tq *TableQuery) *TableReply
QueryTable search/query within the flow table
func (*TableAllocator) Release ¶ added in v0.4.0
func (a *TableAllocator) Release(t *Table)
Release release/destroy a flow table
type TableClient ¶ added in v0.4.0
type TableClient interface { LookupFlows(flowSearchQuery filters.SearchQuery) (*FlowSet, error) LookupFlowsByNodes(hnmap topology.HostNodeTIDMap, flowSearchQuery filters.SearchQuery) (*FlowSet, error) }
TableClient describes a mechanism to query a flow table
type TableOpts ¶ added in v0.12.0
type TableOpts struct { RawPacketLimit int64 ExtraTCPMetric bool IPDefrag bool ReassembleTCP bool LayerKeyMode LayerKeyMode ExtraLayers ExtraLayers }
TableOpts defines flow table options
type TableQuery ¶ added in v0.4.0
type TableQuery struct { Type string `protobuf:"bytes,1,opt,name=Type,proto3" json:"Type,omitempty"` Query *filters.SearchQuery `protobuf:"bytes,2,opt,name=query,proto3" json:"query,omitempty"` }
func (*TableQuery) Descriptor ¶ added in v0.26.0
func (*TableQuery) Descriptor() ([]byte, []int)
func (*TableQuery) GetQuery ¶ added in v0.26.0
func (m *TableQuery) GetQuery() *filters.SearchQuery
func (*TableQuery) GetType ¶ added in v0.26.0
func (m *TableQuery) GetType() string
func (*TableQuery) Marshal ¶ added in v0.26.0
func (m *TableQuery) Marshal() (dAtA []byte, err error)
func (TableQuery) MarshalEasyJSON ¶ added in v0.26.0
func (v TableQuery) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (TableQuery) MarshalJSON ¶ added in v0.26.0
func (v TableQuery) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*TableQuery) MarshalTo ¶ added in v0.26.0
func (m *TableQuery) MarshalTo(dAtA []byte) (int, error)
func (*TableQuery) MarshalToSizedBuffer ¶ added in v0.26.0
func (m *TableQuery) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TableQuery) ProtoMessage ¶ added in v0.26.0
func (*TableQuery) ProtoMessage()
func (*TableQuery) ProtoSize ¶ added in v0.26.0
func (m *TableQuery) ProtoSize() (n int)
func (*TableQuery) Reset ¶ added in v0.26.0
func (m *TableQuery) Reset()
func (*TableQuery) String ¶ added in v0.26.0
func (m *TableQuery) String() string
func (*TableQuery) Unmarshal ¶ added in v0.26.0
func (m *TableQuery) Unmarshal(dAtA []byte) error
func (*TableQuery) UnmarshalEasyJSON ¶ added in v0.26.0
func (v *TableQuery) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*TableQuery) UnmarshalJSON ¶ added in v0.26.0
func (v *TableQuery) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
func (*TableQuery) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *TableQuery) XXX_DiscardUnknown()
func (*TableQuery) XXX_Marshal ¶ added in v0.26.0
func (m *TableQuery) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TableQuery) XXX_Merge ¶ added in v0.26.0
func (m *TableQuery) XXX_Merge(src proto.Message)
func (*TableQuery) XXX_Size ¶ added in v0.26.0
func (m *TableQuery) XXX_Size() int
func (*TableQuery) XXX_Unmarshal ¶ added in v0.26.0
func (m *TableQuery) XXX_Unmarshal(b []byte) error
type TableReply ¶ added in v0.4.0
type TableReply struct { Status int32 `protobuf:"varint,1,opt,name=Status,proto3" json:"Status,omitempty"` FlowSetBytes [][]byte `protobuf:"bytes,2,rep,name=FlowSetBytes,proto3" json:"FlowSetBytes,omitempty"` }
func (*TableReply) Descriptor ¶ added in v0.26.0
func (*TableReply) Descriptor() ([]byte, []int)
func (*TableReply) GetFlowSetBytes ¶ added in v0.26.0
func (m *TableReply) GetFlowSetBytes() [][]byte
func (*TableReply) GetStatus ¶ added in v0.26.0
func (m *TableReply) GetStatus() int32
func (*TableReply) Marshal ¶ added in v0.26.0
func (m *TableReply) Marshal() (dAtA []byte, err error)
func (TableReply) MarshalEasyJSON ¶ added in v0.26.0
func (v TableReply) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (TableReply) MarshalJSON ¶ added in v0.26.0
func (v TableReply) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*TableReply) MarshalTo ¶ added in v0.26.0
func (m *TableReply) MarshalTo(dAtA []byte) (int, error)
func (*TableReply) MarshalToSizedBuffer ¶ added in v0.26.0
func (m *TableReply) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TableReply) ProtoMessage ¶ added in v0.26.0
func (*TableReply) ProtoMessage()
func (*TableReply) ProtoSize ¶ added in v0.26.0
func (m *TableReply) ProtoSize() (n int)
func (*TableReply) Reset ¶ added in v0.26.0
func (m *TableReply) Reset()
func (*TableReply) String ¶ added in v0.26.0
func (m *TableReply) String() string
func (*TableReply) Unmarshal ¶ added in v0.26.0
func (m *TableReply) Unmarshal(dAtA []byte) error
func (*TableReply) UnmarshalEasyJSON ¶ added in v0.26.0
func (v *TableReply) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*TableReply) UnmarshalJSON ¶ added in v0.26.0
func (v *TableReply) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
func (*TableReply) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *TableReply) XXX_DiscardUnknown()
func (*TableReply) XXX_Marshal ¶ added in v0.26.0
func (m *TableReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TableReply) XXX_Merge ¶ added in v0.26.0
func (m *TableReply) XXX_Merge(src proto.Message)
func (*TableReply) XXX_Size ¶ added in v0.26.0
func (m *TableReply) XXX_Size() int
func (*TableReply) XXX_Unmarshal ¶ added in v0.26.0
func (m *TableReply) XXX_Unmarshal(b []byte) error
type TransportLayer ¶ added in v0.26.0
type TransportLayer struct { Protocol FlowProtocol `protobuf:"varint,1,opt,name=Protocol,proto3,enum=flow.FlowProtocol" json:"Protocol"` A int64 `protobuf:"varint,2,opt,name=A,proto3" json:"A"` B int64 `protobuf:"varint,3,opt,name=B,proto3" json:"B"` ID int64 `protobuf:"varint,4,opt,name=ID,proto3" json:"ID"` }
gendecoder
func (*TransportLayer) Descriptor ¶ added in v0.26.0
func (*TransportLayer) Descriptor() ([]byte, []int)
func (*TransportLayer) GetA ¶ added in v0.26.0
func (m *TransportLayer) GetA() int64
func (*TransportLayer) GetB ¶ added in v0.26.0
func (m *TransportLayer) GetB() int64
func (*TransportLayer) GetField ¶ added in v0.26.0
func (obj *TransportLayer) GetField(key string) (interface{}, error)
func (*TransportLayer) GetFieldBool ¶ added in v0.26.0
func (obj *TransportLayer) GetFieldBool(key string) (bool, error)
func (*TransportLayer) GetFieldInt64 ¶ added in v0.26.0
func (obj *TransportLayer) GetFieldInt64(key string) (int64, error)
func (*TransportLayer) GetFieldKeys ¶ added in v0.26.0
func (obj *TransportLayer) GetFieldKeys() []string
func (*TransportLayer) GetFieldString ¶ added in v0.26.0
func (obj *TransportLayer) GetFieldString(key string) (string, error)
func (*TransportLayer) GetID ¶ added in v0.26.0
func (m *TransportLayer) GetID() int64
func (*TransportLayer) GetProtocol ¶ added in v0.26.0
func (m *TransportLayer) GetProtocol() FlowProtocol
func (*TransportLayer) Hash ¶ added in v0.26.0
func (tl *TransportLayer) Hash(hasher hash.Hash, swap bool)
Hash computes the hash of a transport layer
func (*TransportLayer) Marshal ¶ added in v0.26.0
func (m *TransportLayer) Marshal() (dAtA []byte, err error)
func (TransportLayer) MarshalEasyJSON ¶ added in v0.26.0
func (v TransportLayer) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (TransportLayer) MarshalJSON ¶ added in v0.26.0
func (v TransportLayer) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*TransportLayer) MarshalTo ¶ added in v0.26.0
func (m *TransportLayer) MarshalTo(dAtA []byte) (int, error)
func (*TransportLayer) MarshalToSizedBuffer ¶ added in v0.26.0
func (m *TransportLayer) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TransportLayer) MatchBool ¶ added in v0.26.0
func (obj *TransportLayer) MatchBool(key string, predicate getter.BoolPredicate) bool
func (*TransportLayer) MatchInt64 ¶ added in v0.26.0
func (obj *TransportLayer) MatchInt64(key string, predicate getter.Int64Predicate) bool
func (*TransportLayer) MatchString ¶ added in v0.26.0
func (obj *TransportLayer) MatchString(key string, predicate getter.StringPredicate) bool
func (*TransportLayer) ProtoMessage ¶ added in v0.26.0
func (*TransportLayer) ProtoMessage()
func (*TransportLayer) ProtoSize ¶ added in v0.26.0
func (m *TransportLayer) ProtoSize() (n int)
func (*TransportLayer) Reset ¶ added in v0.26.0
func (m *TransportLayer) Reset()
func (*TransportLayer) String ¶ added in v0.26.0
func (m *TransportLayer) String() string
func (*TransportLayer) Unmarshal ¶ added in v0.26.0
func (m *TransportLayer) Unmarshal(dAtA []byte) error
func (*TransportLayer) UnmarshalEasyJSON ¶ added in v0.26.0
func (v *TransportLayer) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*TransportLayer) UnmarshalJSON ¶ added in v0.26.0
func (v *TransportLayer) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
func (*TransportLayer) XXX_DiscardUnknown ¶ added in v0.26.0
func (m *TransportLayer) XXX_DiscardUnknown()
func (*TransportLayer) XXX_Marshal ¶ added in v0.26.0
func (m *TransportLayer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TransportLayer) XXX_Merge ¶ added in v0.26.0
func (m *TransportLayer) XXX_Merge(src proto.Message)
func (*TransportLayer) XXX_Size ¶ added in v0.26.0
func (m *TransportLayer) XXX_Size() int
func (*TransportLayer) XXX_Unmarshal ¶ added in v0.26.0
func (m *TransportLayer) XXX_Unmarshal(b []byte) error
type WSTableClient ¶ added in v0.20.0
type WSTableClient struct {
// contains filtered or unexported fields
}
WSTableClient implements a flow table client using WebSocket
func NewWSTableClient ¶ added in v0.20.0
func NewWSTableClient(w *ws.StructServer) *WSTableClient
NewWSTableClient creates a new table client based on websocket
func (*WSTableClient) LookupFlows ¶ added in v0.20.0
func (f *WSTableClient) LookupFlows(flowSearchQuery filters.SearchQuery) (*FlowSet, error)
LookupFlows query flow table based on a filter search query
func (*WSTableClient) LookupFlowsByNodes ¶ added in v0.20.0
func (f *WSTableClient) LookupFlowsByNodes(hnmap topology.HostNodeTIDMap, flowSearchQuery filters.SearchQuery) (*FlowSet, error)
LookupFlowsByNodes query flow table based on multiple nodes
type WSTableServer ¶ added in v0.20.0
type WSTableServer struct {
TableAllocator *TableAllocator
}
WSTableServer describes a mechanism to Query a flow table via Websocket
func NewWSTableServer ¶ added in v0.20.0
func NewWSTableServer(allocator *TableAllocator, pool ws.StructSpeakerPool) *WSTableServer
NewWSTableServer creates a new flow table query server based on websocket
func (*WSTableServer) OnStructMessage ¶ added in v0.20.0
func (s *WSTableServer) OnStructMessage(c ws.Speaker, msg *ws.StructMessage)
OnStructMessage TableQuery
func (*WSTableServer) OnTableQuery ¶ added in v0.20.0
func (s *WSTableServer) OnTableQuery(c ws.Speaker, msg *ws.StructMessage)
OnTableQuery event