suricata
source-ipfw.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  IPFWPacketVars_
 
struct  IPFWQueueVars_
 

Macros

#define IPFW_MAX_QUEUE   16
 

Typedefs

typedef struct IPFWPacketVars_ IPFWPacketVars
 
typedef struct IPFWQueueVars_ IPFWQueueVars
 

Functions

void * IPFWGetThread (int number)
 Get a pointer to the IPFW thread at index. More...
 
int IPFWRegisterQueue (char *queue)
 Add an IPFW divert. More...
 
void TmModuleReceiveIPFWRegister (void)
 Registration Function for RecieveIPFW. More...
 
void TmModuleVerdictIPFWRegister (void)
 Registration Function for VerdictIPFW. More...
 
void TmModuleDecodeIPFWRegister (void)
 Registration Function for DecodeIPFW. More...
 

Detailed Description

Macro Definition Documentation

#define IPFW_MAX_QUEUE   16

Definition at line 28 of file source-ipfw.h.

Referenced by IPFWRegisterQueue().

Typedef Documentation

typedef struct IPFWQueueVars_ IPFWQueueVars

Function Documentation

void* IPFWGetThread ( int  number)

Get a pointer to the IPFW thread at index.

This function is temporary used as configuration parser.

Parameters
numberidx of the queue in our array
Return values
ptrpointer to the IPFWThreadVars at index
NULLon error

Definition at line 778 of file source-ipfw.c.

Referenced by RunModeIpsIPFWAutoFp(), and RunModeIpsIPFWWorker().

Here is the caller graph for this function:

int IPFWRegisterQueue ( char *  queue)

Add an IPFW divert.

Parameters
stringwith the queue name
Return values
0on success.
-1on failure.

Definition at line 713 of file source-ipfw.c.

References ByteExtractStringUint16(), IPFWThreadVars_::ipfw_index, IPFW_MAX_QUEUE, LiveRegisterDeviceName(), IPFWQueueVars_::port_num, IPFWThreadVars_::port_num, SC_ERR_INVALID_ARGUMENT, SCLogDebug, SCLogError, SCMutexLock, and SCMutexUnlock.

Referenced by RegisterAllModules().

Here is the call graph for this function:

Here is the caller graph for this function:

void TmModuleDecodeIPFWRegister ( void  )
void TmModuleReceiveIPFWRegister ( void  )
void TmModuleVerdictIPFWRegister ( void  )

Registration Function for VerdictIPFW.

Todo:
Unit tests are needed for this module.
Todo:
untested

Definition at line 175 of file source-ipfw.c.

References TmModule_::cap_flags, TmModule_::Func, TmModule_::name, TmModule_::RegisterTests, SC_CAP_NET_ADMIN, SC_CAP_NET_BIND_SERVICE, SC_CAP_NET_RAW, TmModule_::ThreadDeinit, TmModule_::ThreadExitPrintStats, TmModule_::ThreadInit, tmm_modules, TMM_VERDICTIPFW, VerdictIPFW(), VerdictIPFWThreadDeinit(), VerdictIPFWThreadExitStats(), and VerdictIPFWThreadInit().

Referenced by RegisterAllModules().

Here is the call graph for this function:

Here is the caller graph for this function: