suricata
flow-storage.c File Reference
#include "suricata-common.h"
#include "flow-storage.h"
#include "flow-hash.h"
#include "flow-util.h"
#include "util-unittest.h"
Include dependency graph for flow-storage.c:

Go to the source code of this file.

Functions

unsigned int FlowStorageSize (void)
 
void * FlowGetStorageById (Flow *f, int id)
 
int FlowSetStorageById (Flow *f, int id, void *ptr)
 
void * FlowAllocStorageById (Flow *f, int id)
 
void FlowFreeStorageById (Flow *f, int id)
 
void FlowFreeStorage (Flow *f)
 
int FlowStorageRegister (const char *name, const unsigned int size, void *(*Alloc)(unsigned int), void(*Free)(void *))
 
void RegisterFlowStorageTests (void)
 

Detailed Description

Author
Eric Leblond eric@.nosp@m.regi.nosp@m.t.org

based on host-storage by Victor Julien victo.nosp@m.r@in.nosp@m.linia.nosp@m.c.ne.nosp@m.t

Flow wrapper around storage api

Definition in file flow-storage.c.

Function Documentation

◆ FlowAllocStorageById()

void* FlowAllocStorageById ( Flow f,
int  id 
)

Definition at line 49 of file flow-storage.c.

References STORAGE_FLOW, and StorageAllocByIdPrealloc().

Here is the call graph for this function:

◆ FlowFreeStorage()

void FlowFreeStorage ( Flow f)

Definition at line 59 of file flow-storage.c.

References FlowStorageSize(), STORAGE_FLOW, and StorageFreeAll().

Referenced by FlowClearMemory().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FlowFreeStorageById()

void FlowFreeStorageById ( Flow f,
int  id 
)

Definition at line 54 of file flow-storage.c.

References STORAGE_FLOW, and StorageFreeById().

Here is the call graph for this function:

◆ FlowGetStorageById()

void* FlowGetStorageById ( Flow f,
int  id 
)

Definition at line 39 of file flow-storage.c.

References STORAGE_FLOW, and StorageGetById().

Referenced by JsonAddFlow(), and TagFlowAdd().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FlowSetStorageById()

int FlowSetStorageById ( Flow f,
int  id,
void *  ptr 
)

Definition at line 44 of file flow-storage.c.

References STORAGE_FLOW, and StorageSetById().

Referenced by PacketBypassCallback().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FlowStorageRegister()

int FlowStorageRegister ( const char *  name,
const unsigned int  size,
void *(*)(unsigned int)  Alloc,
void(*)(void *)  Free 
)

Definition at line 65 of file flow-storage.c.

References STORAGE_FLOW, and StorageRegister().

Referenced by RegisterFlowBypassInfo().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FlowStorageSize()

unsigned int FlowStorageSize ( void  )

Definition at line 34 of file flow-storage.c.

References STORAGE_FLOW, and StorageGetSize().

Referenced by FlowAlloc(), FlowFree(), FlowFreeStorage(), and FlowInitConfig().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ RegisterFlowStorageTests()

void RegisterFlowStorageTests ( void  )

Definition at line 289 of file flow-storage.c.

References UtRegisterTest().

Here is the call graph for this function: