suricata
util-action.h File Reference
#include "suricata-common.h"
Include dependency graph for util-action.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

int ActionInitConfig (void)
 Load the action order from config. If none is provided, it will be default to ACTION_PASS, ACTION_DROP, ACTION_REJECT, ACTION_ALERT (pass has the highest prio) More...
 
uint8_t ActionOrderVal (uint8_t)
 Return the priority associated to an action (to order sigs as specified at config) action_order_sigs has this priority by index val so action_order_sigs[0] has to be inspected first. This function is called from detect-engine-sigorder. More...
 
void UtilActionRegisterTests (void)
 

Detailed Description

Function Documentation

int ActionInitConfig ( void  )

Load the action order from config. If none is provided, it will be default to ACTION_PASS, ACTION_DROP, ACTION_REJECT, ACTION_ALERT (pass has the highest prio)

Return values
0on success; -1 on fatal error;

Definition at line 98 of file util-action.c.

References ACTION_ALERT, ACTION_DROP, action_order_sigs, ACTION_PASS, ACTION_REJECT, ActionInitConfig(), ConfCreateContextBackup(), ConfGetNode(), ConfInit(), ConfRestoreContextBackup(), ConfYamlLoadString(), DE_QUIET, DetectEngineCtxFree(), DetectEngineCtxInit(), DetectEngineCtx_::flags, next, res, SC_ERR_ACTION_ORDER, SCLogDebug, SCLogError, SCSigOrderSignatures(), SCSigRegisterSignatureOrderingFuncs(), SigCleanSignatures(), SigGroupCleanup(), TAILQ_FOREACH, UTHAppendSigs(), UTHBuildPacketReal(), UTHFreePackets(), UTHMatchPacketsWithResults(), and ConfNode_::val.

Referenced by ActionInitConfig(), and DetectEngineInspectBufferGeneric().

Here is the call graph for this function:

Here is the caller graph for this function:

uint8_t ActionOrderVal ( uint8_t  action)

Return the priority associated to an action (to order sigs as specified at config) action_order_sigs has this priority by index val so action_order_sigs[0] has to be inspected first. This function is called from detect-engine-sigorder.

Parameters
actioncan be one of ACTION_PASS, ACTION_DROP, ACTION_REJECT or ACTION_ALERT
Return values
uint8_tthe priority (order of this actions)

Definition at line 53 of file util-action.c.

References ACTION_ALERT, ACTION_DROP, action_order_sigs, ACTION_PASS, ACTION_REJECT, ACTION_REJECT_BOTH, and ACTION_REJECT_DST.

void UtilActionRegisterTests ( void  )

Definition at line 1596 of file util-action.c.

References UtRegisterTest().

Here is the call graph for this function: