Go to the documentation of this file.
40 static int DetectIGMPTypeMatch(
46 static bool PrefilterIGMPTypeIsPrefilterable(
const Signature *s);
75 static int DetectIGMPTypeMatch(
80 if (!PacketIsIGMP(p)) {
85 const IGMPHdr *igmph = PacketGetIGMP(p);
138 static void PrefilterPacketIGMPTypeMatch(
143 if (PacketIsIGMP(p)) {
144 const IGMPHdr *igmph = PacketGetIGMP(p);
149 PrefilterAddSids(&det_ctx->
pmq, sa->
sigs, sa->
cnt);
158 PrefilterPacketIGMPTypeMatch);
161 static bool PrefilterIGMPTypeIsPrefilterable(
const Signature *s)
#define SIG_MASK_REQUIRE_REAL_PKT
SigTableElmt * sigmatch_table
void(* Free)(DetectEngineCtx *, void *)
#define PKT_IS_PSEUDOPKT(p)
return 1 if the packet is a pseudo packet
Container for matching data for a signature group.
main detection engine ctx
int(* Setup)(DetectEngineCtx *, Signature *, const char *)
int(* SetupPrefilter)(DetectEngineCtx *de_ctx, struct SigGroupHead_ *sgh)
DetectUintData_u8 * DetectU8Parse(const char *u8str)
This function is used to parse u8 options passed via some u8 keyword.
int PrefilterSetupPacketHeaderU8Hash(DetectEngineCtx *de_ctx, SigGroupHead *sgh, int sm_type, SignatureMask mask, void(*Set)(PrefilterPacketHeaderValue *v, void *), bool(*Compare)(PrefilterPacketHeaderValue v, void *), void(*Match)(DetectEngineThreadCtx *det_ctx, Packet *p, const void *pectx))
SigMatch * SCSigMatchAppendSMToList(DetectEngineCtx *de_ctx, Signature *s, uint16_t type, SigMatchCtx *ctx, const int list)
Append a SigMatch to the list type.
DetectUintData_u8 DetectU8Data
void PrefilterPacketU8Set(PrefilterPacketHeaderValue *v, void *smctx)
int(* Match)(DetectEngineThreadCtx *, Packet *, const Signature *, const SigMatchCtx *)
Used to start a pointer to SigMatch context Should never be dereferenced without casting to something...
#define DETECT_PROTO_IPV4
int DetectU8Match(const uint8_t parg, const DetectUintData_u8 *du8)
void DetectIGMPTypeRegister(void)
Registration function for igmp.type keyword.
bool(* SupportsPrefilter)(const Signature *s)
void DetectIGMPTypeFree(DetectEngineCtx *, void *)
this function will free memory associated with DetectU8Data
#define SIGMATCH_INFO_UINT8
bool PrefilterPacketU8Compare(PrefilterPacketHeaderValue v, void *smctx)
#define DEBUG_VALIDATE_BUG_ON(exp)
int DetectProtoContainsProto(const DetectProto *dp, int proto)
see if a DetectProto contains a certain proto
#define SIG_FLAG_REQUIRE_PACKET