Go to the documentation of this file.
37 #define KEYWORD_NAME_SRC "ip.src"
38 #define KEYWORD_NAME_DST "ip.dst"
50 static int g_src_ipaddr_buffer_id = 0;
51 static int g_dest_ipaddr_buffer_id = 0;
66 BUG_ON(g_src_ipaddr_buffer_id < 0);
83 BUG_ON(g_dest_ipaddr_buffer_id < 0);
123 if (PacketIsIPv4(p)) {
126 }
else if (PacketIsIPv6(p)) {
147 if (PacketIsIPv4(p)) {
150 }
else if (PacketIsIPv6(p)) {
int PrefilterGenericMpmPktRegister(DetectEngineCtx *de_ctx, SigGroupHead *sgh, MpmCtx *mpm_ctx, const DetectBufferMpmRegistry *mpm_reg, int list_id)
#define SIGMATCH_INFO_STICKY_BUFFER
SigTableElmt * sigmatch_table
void DetectPktMpmRegister(const char *name, int priority, int(*PrefilterRegister)(DetectEngineCtx *de_ctx, SigGroupHead *sgh, MpmCtx *mpm_ctx, const DetectBufferMpmRegistry *mpm_reg, int list_id), InspectionBufferGetPktDataPtr GetData)
register a MPM engine
union Address_::@26 address
main detection engine ctx
int(* Setup)(DetectEngineCtx *, Signature *, const char *)
InspectionBuffer * InspectionBufferGet(DetectEngineThreadCtx *det_ctx, const int list_id)
void DetectBufferTypeSupportsPacket(const char *name)
void DetectPktInspectEngineRegister(const char *name, InspectionBufferGetPktDataPtr GetPktData, InspectionBufferPktInspectFunc Callback)
register inspect engine at start up time
uint8_t address_un_data8[16]
SignatureInitData * init_data
void DetectIPAddrRegisterTests(void)
this function registers unit tests for DetectIpv4hdr
int DetectBufferTypeRegister(const char *name)
void InspectionBufferApplyTransforms(InspectionBuffer *buffer, const DetectEngineTransforms *transforms)
void InspectionBufferSetup(DetectEngineThreadCtx *det_ctx, const int list_id, InspectionBuffer *buffer, const uint8_t *data, const uint32_t data_len)
setup the buffer with our initial data
void DetectIPAddrBufferRegister(void)
int DetectEngineInspectPktBufferGeneric(DetectEngineThreadCtx *det_ctx, const DetectEnginePktInspectionEngine *engine, const Signature *s, Packet *p, uint8_t *_alert_flags)
Do the content inspection & validation for a signature.
void(* RegisterTests)(void)