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

Go to the source code of this file.

Macros

#define OUTPUT_FILEDATA_FLAG_OPEN   0x01
 
#define OUTPUT_FILEDATA_FLAG_CLOSE   0x02
 

Typedefs

typedef int(* FiledataLogger) (ThreadVars *, void *thread_data, const Packet *, File *, const uint8_t *, uint32_t, uint8_t, uint8_t dir)
 

Functions

int OutputRegisterFiledataLogger (LoggerId id, const char *name, FiledataLogger LogFunc, OutputCtx *, ThreadInitFunc ThreadInit, ThreadDeinitFunc ThreadDeinit, ThreadExitPrintStatsFunc ThreadExitPrintStats)
 
void OutputFiledataLoggerRegister (void)
 
void OutputFiledataShutdown (void)
 

Detailed Description

Author
Victor Julien victo.nosp@m.r@in.nosp@m.linia.nosp@m.c.ne.nosp@m.t

AppLayer Filedata Logger Output registration functions

Definition in file output-filedata.h.

Macro Definition Documentation

#define OUTPUT_FILEDATA_FLAG_CLOSE   0x02

Definition at line 33 of file output-filedata.h.

Referenced by OutputRegisterFiledataLogger().

#define OUTPUT_FILEDATA_FLAG_OPEN   0x01

Definition at line 32 of file output-filedata.h.

Referenced by OutputRegisterFiledataLogger().

Typedef Documentation

typedef int(* FiledataLogger) (ThreadVars *, void *thread_data, const Packet *, File *, const uint8_t *, uint32_t, uint8_t, uint8_t dir)

filedata logger function pointer type

Definition at line 36 of file output-filedata.h.

Function Documentation

void OutputFiledataLoggerRegister ( void  )

Definition at line 438 of file output-filedata.c.

References OutputRegisterRootLogger(), and SC_ATOMIC_INIT.

Referenced by OutputRegisterRootLoggers().

Here is the call graph for this function:

Here is the caller graph for this function:

void OutputFiledataShutdown ( void  )

Definition at line 446 of file output-filedata.c.

References OutputFiledataLogger_::next, and SCFree.

Referenced by RunModeShutDown().

Here is the caller graph for this function:

int OutputRegisterFiledataLogger ( LoggerId  id,
const char *  name,
FiledataLogger  LogFunc,
OutputCtx ,
ThreadInitFunc  ThreadInit,
ThreadDeinitFunc  ThreadDeinit,
ThreadExitPrintStatsFunc  ThreadExitPrintStats 
)

packet logger condition function pointer type, must return true for packets that should be logged

Definition at line 68 of file output-filedata.c.

References Flow_::alproto, Flow_::alstate, AppLayerParserGetFiles(), BUG_ON, ConfGetNode(), ConfigGetLogDirectory(), ConfNodeLookupChild(), File_::content_stored, DEBUG_VALIDATE_BUG_ON, FILE_STATE_CLOSED, FILE_STORE, File_::file_store_id, FILE_STORED, FILE_TRUNCATED, FileCloseFilePtr(), FileDataSize(), FileForceMagic(), File_::flags, flags, Packet_::flags, Packet_::flow, FLOW_PKT_TOCLIENT, FLOW_PKT_TOSERVER, Packet_::flowflags, FileContainer_::head, OutputFiledataLogger_::LogFunc, OutputFiledataLogger_::logger_id, OutputFiledataLogger_::name, OutputLoggerThreadStore_::next, OutputFiledataLogger_::next, File_::next, OutputFiledataLogger_::output_ctx, OUTPUT_FILEDATA_FLAG_CLOSE, OUTPUT_FILEDATA_FLAG_OPEN, PACKET_PROFILING_LOGGER_END, PACKET_PROFILING_LOGGER_START, PathIsAbsolute(), PKT_PSEUDO_STREAM_END, Packet_::proto, File_::sb, SC_ATOMIC_ADD, SC_ATOMIC_CAS, SC_ATOMIC_DECLARE(), SC_ATOMIC_GET, SC_ERR_FWRITE, SCFree, SCLogDebug, SCLogError, SCLogInfo, SCMalloc, SCMutexLock, SCMutexUnlock, SCReturn, SCReturnInt, File_::state, OutputLoggerThreadData_::store, STREAM_TOCLIENT, STREAM_TOSERVER, StreamingBufferGetDataAtOffset(), StreamTcpReassembleDepthReached(), TAILQ_FOREACH, OutputLoggerThreadStore_::thread_data, OutputFiledataLogger_::ThreadDeinit, OutputFiledataLogger_::ThreadExitPrintStats, OutputFiledataLogger_::ThreadInit, TM_ECODE_FAILED, TM_ECODE_OK, ts, and ConfNode_::val.

Referenced by RunModeShutDown().

Here is the call graph for this function:

Here is the caller graph for this function: