suricata
Packet_ Struct Reference

#include <decode.h>

Collaboration diagram for Packet_:

Data Fields

Address src
 
Address dst
 
union {
   Port   sp
 
   struct {
      uint8_t   type
 
      uint8_t   code
 
   }   icmp_s
 
}; 
 
union {
   Port   dp
 
   struct {
      uint8_t   type
 
      uint8_t   code
 
   }   icmp_d
 
}; 
 
uint8_t proto
 
uint8_t recursion_level
 
uint16_t vlan_id [2]
 
uint8_t vlan_idx
 
uint8_t flowflags
 
uint32_t flags
 
struct Flow_flow
 
uint32_t flow_hash
 
struct timeval ts
 
union {
   NFQPacketVars   nfq_v
 
   IPFWPacketVars   ipfw_v
 
   PcapPacketVars   pcap_v
 
}; 
 
void(* ReleasePacket )(struct Packet_ *)
 
int(* BypassPacketsFlow )(struct Packet_ *)
 
PktVarpktvar
 
EthernetHdr * ethh
 
int32_t level3_comp_csum
 
int32_t level4_comp_csum
 
IPV4Hdrip4h
 
IPV6Hdrip6h
 
union {
   IPV4Vars   ip4vars
 
   struct {
      IPV6Vars   ip6vars
 
      IPV6ExtHdrs   ip6eh
 
   } 
 
}; 
 
union {
   TCPVars   tcpvars
 
   ICMPV4Vars   icmpv4vars
 
   ICMPV6Vars   icmpv6vars
 
l4vars
 
TCPHdr * tcph
 
UDPHdr * udph
 
SCTPHdr * sctph
 
ICMPV4Hdr * icmpv4h
 
ICMPV6Hdricmpv6h
 
PPPHdr * ppph
 
PPPOESessionHdrpppoesh
 
PPPOEDiscoveryHdr * pppoedh
 
GREHdr * greh
 
uint8_t * payload
 
uint16_t payload_len
 
uint8_t action
 
uint8_t pkt_src
 
uint32_t pktlen
 
uint8_t * ext_pkt
 
struct LiveDevice_livedev
 
PacketAlerts alerts
 
struct Host_host_src
 
struct Host_host_dst
 
uint64_t pcap_cnt
 
PacketEngineEvents events
 
AppLayerDecoderEventsapp_layer_events
 
struct Packet_next
 
struct Packet_prev
 
int datalink
 
struct Packet_root
 
SCMutex tunnel_mutex
 
uint16_t tunnel_rtv_cnt
 
uint16_t tunnel_tpr_cnt
 
uint32_t tenant_id
 
struct PktPool_pool
 
PktProfilingprofile
 
NapatechPacketVars ntpv
 

Detailed Description

Definition at line 408 of file decode.h.

Field Documentation

union { ... }
union { ... }
union { ... }
union { ... }
int(* Packet_::BypassPacketsFlow) (struct Packet_ *)

The function triggering bypass the flow in the capture method. Return 1 for success and 0 on error

Definition at line 488 of file decode.h.

Referenced by DetectBypassRegister(), PacketBypassCallback(), ReceivePfringLoop(), and TmModuleDecodeAFPRegister().

uint8_t Packet_::code

Definition at line 420 of file decode.h.

EthernetHdr* Packet_::ethh

Definition at line 494 of file decode.h.

Referenced by DecodeEthernet(), and TmModuleDecodeAFPRegister().

PacketEngineEvents Packet_::events
uint8_t* Packet_::ext_pkt
uint32_t Packet_::flags

Definition at line 444 of file decode.h.

Referenced by AlertJsonHeader(), AppLayerIncTxCounter(), CaptureStatsUpdate(), CleanupPcapFileFileVars(), DecodeAFP(), DecodeErfDag(), DecodeErfFile(), DecodeIPFW(), DecodeIPV4(), DecodeIPV6FragHeader(), DecodePcap(), DecodePfring(), DefragTrackerFreeFrags(), DetectBufferTypeGetByIdTransforms(), DetectBypassRegister(), DetectCsumRegister(), DetectDceIfaceRegister(), DetectDceOpnumRegister(), DetectDceStubDataRegister(), DetectDNP3Register(), DetectDnsQueryRegister(), DetectEngineInspectENIP(), DetectEngineInspectModbus(), DetectEngineInspectPktBufferGeneric(), DetectEngineInspectStream(), DetectEngineStateResetTxs(), DetectFlowFree(), DetectFlowMatch(), DetectFtpbounceRegister(), DetectHostbitFree(), DetectHttpRequestLineRegister(), DetectHttpResponseLineRegister(), DetectIPRepRegister(), DetectLuaRegister(), DetectMarkDataFree(), DetectPcrePayloadMatch(), DetectProtoContainsProto(), DetectReplaceExecuteInternal(), DetectSignatureApplyActions(), DetectSshSoftwareVersionRegister(), DetectSshVersionRegister(), DetectTemplateRustBufferRegister(), DetectUricontentRegister(), DetectUrilenValidateContent(), FlowHandlePacket(), FlowHandlePacketUpdate(), FlowSetupPacket(), HtpConfigRestoreBackup(), IPOnlyAddSignature(), IPOnlyMatchPacket(), NapatechDecode(), NFQInitConfig(), NFQSetVerdict(), OutputRegisterFiledataLogger(), OutputRegisterFileLogger(), PacketAlertFinalize(), PacketCreateMask(), PacketDecodeFinalize(), PacketFreeOrRelease(), PacketGetFromAlloc(), PacketPoolWaitForN(), PacketSetData(), PacketTunnelPktSetup(), PcapFileGlobalInit(), Prefilter(), ReceiveNFQThreadExitStats(), RegisterModbusParsers(), SCProfileRuleStart(), SCSigSignatureOrderingModuleCleanup(), SigMatchSignaturesGetSgh(), SMTPParserCleanup(), StreamNeedsReassembly(), StreamReassembleRaw(), StreamReassembleRawHasDataReady(), StreamReassembleRawUpdateProgress(), StreamTcp(), StreamTcpInlineSegmentReplacePacket(), StreamTcpPacket(), StreamTcpPseudoSetup(), StreamTcpReassembleAppLayer(), StreamTcpReassembleHandleSegment(), StreamTcpReassembleHandleSegmentHandleData(), TagHashAddTag(), TmModuleDecodeAFPRegister(), TmModuleDecodeNetmapRegister(), TmModuleDecodePcapRegister(), TmModuleDecodePfringRegister(), TmqhOutputFlowHash(), TmqhOutputPacketpool(), TmqhOutputSimple(), Unified2Condition(), UTHAssignFlow(), and VerdictIPFW().

struct Flow_* Packet_::flow

Definition at line 446 of file decode.h.

Referenced by AFPSetBPFFilter(), AlertJsonHeader(), CreateJSONHeader(), Detect(), DetectBufferTypeGetByIdTransforms(), DetectBypassRegister(), DetectDceIfaceRegister(), DetectDceOpnumRegister(), DetectDceStubDataRegister(), DetectDNP3Register(), DetectDnsQueryRegister(), DetectEngineInspectENIP(), DetectEngineInspectModbus(), DetectEngineInspectPktBufferGeneric(), DetectEngineStateResetTxs(), DetectFilestoreRegister(), DetectFlowbitsRegister(), DetectFlowintMatch(), DetectFlowvarMatch(), DetectFlowvarPostMatchSetup(), DetectFtpbounceRegister(), DetectHostbitFree(), DetectHttpRequestLineRegister(), DetectHttpResponseLineRegister(), DetectLuaRegister(), DetectPcrePayloadMatch(), DetectProtoContainsProto(), DetectRunPrefilterTx(), DetectSignatureApplyActions(), DetectSshSoftwareVersionRegister(), DetectSshVersionRegister(), DetectStreamSizeFree(), DetectStreamSizeRegister(), DetectTagRegister(), DetectTemplateRustBufferRegister(), DetectTlsRegister(), DetectUricontentRegister(), DetectUrilenValidateContent(), FlowForceReassemblyForFlow(), FlowHandlePacket(), HtpConfigRestoreBackup(), IPOnlyAddSignature(), JsonBuildFileInfoRecord(), JsonHttpLogJSONBodyBase64(), OutputRegisterFiledataLogger(), OutputRegisterFileLogger(), OutputRegisterTxLogger(), PacketAlertFinalize(), PacketBypassCallback(), RegisterModbusParsers(), SCSigSignatureOrderingModuleCleanup(), SMTPParserCleanup(), StreamNeedsReassembly(), StreamTcp(), StreamTcpFreeConfig(), StreamTcpPacket(), StreamTcpPseudoSetup(), StreamTcpReassembleAppLayer(), StreamTcpReassembleDepthReached(), StreamTcpSegmentForEach(), StreamTcpSessionPktFree(), TagFlowAdd(), TagHandlePacket(), TagHashAddTag(), TagTimeoutCheck(), Unified2Logger(), UTHAssignFlow(), and UTHBuildPacketOfFlows().

uint32_t Packet_::flow_hash

Definition at line 450 of file decode.h.

Referenced by DecodeIPV4(), FlowGetFlowFromHash(), FlowSetupPacket(), and TmqhOutputFlowHash().

GREHdr* Packet_::greh

Definition at line 537 of file decode.h.

Referenced by DecodeGRE().

struct Host_* Packet_::host_dst

Definition at line 559 of file decode.h.

Referenced by DetectHostbitsRegister(), and DetectIPRepRegister().

struct Host_* Packet_::host_src

Definition at line 558 of file decode.h.

Referenced by DetectHostbitFree(), DetectHostbitsRegister(), and DetectIPRepRegister().

struct { ... } Packet_::icmp_d
struct { ... } Packet_::icmp_s
ICMPV4Vars Packet_::icmpv4vars
ICMPV6Hdr* Packet_::icmpv6h

Definition at line 531 of file decode.h.

Referenced by CreateJSONHeader(), DecodeICMPV6(), DetectCsumRegister(), and FlowInit().

ICMPV6Vars Packet_::icmpv6vars

Definition at line 517 of file decode.h.

Referenced by DecodeICMPV6().

IPV4Vars Packet_::ip4vars

Definition at line 507 of file decode.h.

Referenced by DetectIpOptsFree().

IPV6ExtHdrs Packet_::ip6eh

Definition at line 510 of file decode.h.

Referenced by DecodeIPV6(), DecodeIPV6FragHeader(), and DefragRbFragCompare().

IPV6Vars Packet_::ip6vars

Definition at line 509 of file decode.h.

IPFWPacketVars Packet_::ipfw_v

Definition at line 463 of file decode.h.

Referenced by IPFWSetVerdict().

union { ... } Packet_::l4vars
int32_t Packet_::level3_comp_csum

Definition at line 497 of file decode.h.

Referenced by DetectCsumRegister().

int32_t Packet_::level4_comp_csum

Definition at line 499 of file decode.h.

Referenced by DetectCsumRegister(), and StreamTcpPacket().

NFQPacketVars Packet_::nfq_v

Definition at line 460 of file decode.h.

Referenced by DetectMarkDataFree(), NFQInitConfig(), and NFQSetVerdict().

NapatechPacketVars Packet_::ntpv

Definition at line 606 of file decode.h.

Referenced by NapatechPacketLoopZC(), and NapatechStreamThreadInit().

PcapPacketVars Packet_::pcap_v

libpcap vars: shared by Pcap Live mode and Pcap File mode

Definition at line 481 of file decode.h.

Referenced by CleanupPcapFileFileVars(), and DetectEngineTentantUnregisterPcapFile().

uint8_t Packet_::pkt_src

Definition at line 547 of file decode.h.

Referenced by PcapFileGlobalInit().

uint32_t Packet_::pktlen

Definition at line 550 of file decode.h.

PktVar* Packet_::pktvar

Definition at line 491 of file decode.h.

Referenced by JsonAddStringN(), PktVarAdd(), PktVarAddKeyValue(), and PktVarGet().

struct PktPool_* Packet_::pool

Definition at line 600 of file decode.h.

Referenced by PacketPoolGetPacket(), PacketPoolReturnPacket(), and PacketPoolWaitForN().

PPPHdr* Packet_::ppph

Definition at line 533 of file decode.h.

Referenced by DecodeIPV4(), and DecodePPP().

PPPOEDiscoveryHdr* Packet_::pppoedh

Definition at line 535 of file decode.h.

Referenced by DecodePPPOEDiscovery(), and DecodePPPOESession().

PPPOESessionHdr* Packet_::pppoesh

Definition at line 534 of file decode.h.

Referenced by DecodePPPOESession().

struct Packet_* Packet_::prev

Definition at line 572 of file decode.h.

Referenced by PacketDequeue(), and PacketEnqueue().

PktProfiling* Packet_::profile
void(* Packet_::ReleasePacket) (struct Packet_ *)

The release function for packet structure and data

Definition at line 485 of file decode.h.

Referenced by NapatechPacketLoopZC(), PacketGetFromAlloc(), PacketPoolWaitForN(), TmModuleDecodeAFPRegister(), TmModuleDecodeNetmapRegister(), and TmqhOutputPacketpool().

SCTPHdr* Packet_::sctph

Definition at line 527 of file decode.h.

Referenced by DecodeSCTP(), and FlowInit().

TCPVars Packet_::tcpvars

Definition at line 515 of file decode.h.

uint32_t Packet_::tenant_id

tenant id for this packet, if any. If 0 then no tenant was assigned.

Definition at line 595 of file decode.h.

Referenced by AlertJsonHeader(), Detect(), PacketDefragPktSetup(), PacketTunnelPktSetup(), SigMatchSignaturesGetSgh(), and StreamTcpPseudoSetup().

SCMutex Packet_::tunnel_mutex

mutex to protect access to:

  • tunnel_rtv_cnt
  • tunnel_tpr_cnt

Definition at line 588 of file decode.h.

Referenced by AlertJsonHeader(), DetectMarkDataFree(), and TmqhOutputPacketpool().

uint16_t Packet_::tunnel_rtv_cnt

Definition at line 590 of file decode.h.

uint16_t Packet_::tunnel_tpr_cnt

Definition at line 592 of file decode.h.

uint8_t Packet_::type

Definition at line 419 of file decode.h.

Referenced by ReceiveErfDagLoop().


The documentation for this struct was generated from the following file: