tcpflow  1.6.1
About: tcpflow is a TCP/IP packet demultiplexer that captures data transmitted as part of TCP connections (flows), and stores the data in a way that is convenient for protocol analysis and debugging.
  Fossies Dox: tcpflow-1.6.1.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

Loading...
Searching...
No Matches
feature_recorder_set Class Reference

#include <feature_recorder_set.h>

Collaboration diagram for feature_recorder_set:
[legend]

Classes

struct  hash_def
 
struct  pstats
 

Public Types

typedef std::map< std::string, struct pstatsscanner_stats_map
 
typedef void(* xml_notifier_t) (const std::string &xmlstring)
 
typedef int(* stat_callback_t) (void *user, const std::string &name, uint64_t calls, double seconds)
 

Public Member Functions

virtual void heartbeat ()
 
 feature_recorder_set (uint32_t flags_, const hash_def &hasher_, const std::string &input_fname_, const std::string &outdir_)
 
virtual ~feature_recorder_set ()
 
std::string get_input_fname () const
 
virtual const std::string & get_outdir () const
 
void set_stop_list (const word_and_context_list *alist)
 
void set_alert_list (const word_and_context_list *alist)
 
void init (const feature_file_names_t &feature_files)
 
void flush_all ()
 
void close_all ()
 
bool has_name (std::string name) const
 
void set_flag (uint32_t f)
 
void unset_flag (uint32_t f)
 
bool flag_set (uint32_t f) const
 
bool flag_notset (uint32_t f) const
 
uint32_t get_flags () const
 
void add_histogram (const histogram_def &def)
 
void dump_histograms (void *user, feature_recorder::dump_callback_t cb, xml_notifier_t xml_error_notifier) const
 
virtual feature_recordercreate_name_factory (const std::string &name_)
 
virtual void create_name (const std::string &name, bool create_stop_also)
 
void add_stats (const std::string &bucket, double seconds)
 
void get_stats (void *user, stat_callback_t stat_callback) const
 
void dump_name_count_stats (dfxml_writer &writer) const
 
virtual void db_send_sql (void *db3, const char **stmts,...)
 
virtual void * db_create_empty (const std::string &name)
 
void db_create_table (const std::string &name)
 
void db_create ()
 
void db_transaction_begin ()
 
void db_transaction_commit ()
 
void db_close ()
 
virtual bool check_previously_processed (const uint8_t *buf, size_t bufsize)
 
virtual feature_recorderget_name (const std::string &name) const
 
virtual feature_recorderget_alert_recorder () const
 
virtual void get_feature_file_list (std::vector< std::string > &ret)
 

Public Attributes

void * db3
 
const word_and_context_listalert_list
 
const word_and_context_liststop_list
 
scanner_stats_map scanner_stats
 
const hash_defhasher
 

Static Public Attributes

static hash_def null_hasher
 
static const std::string ALERT_RECORDER_NAME = "alerts"
 
static const std::string DISABLED_RECORDER_NAME = "disabled"
 
static const std::string NO_INPUT = "<NO-INPUT>"
 
static const std::string NO_OUTDIR = "<NO-OUTDIR>"
 
static const uint32_t ONLY_ALERT = 0x01
 
static const uint32_t SET_DISABLED = 0x02
 
static const uint32_t CREATE_STOP_LIST_RECORDERS = 0x04
 
static const uint32_t MEM_HISTOGRAM = 0x20
 
static const uint32_t ENABLE_SQLITE3_RECORDERS = 0x40
 
static const uint32_t DISABLE_FILE_RECORDERS = 0x80
 
static const uint32_t NO_ALERT = 0x100
 

Private Member Functions

 feature_recorder_set (const feature_recorder_set &fs)
 
feature_recorder_setoperator= (const feature_recorder_set &fs)
 

Private Attributes

uint32_t flags
 
atomic_set< std::string > seen_set
 
const std::string input_fname
 
const std::string outdir
 
feature_recorder_map frm
 
cppmutex Mscanner_stats
 
histogram_defs_t histogram_defs
 
cppmutex Min_transaction
 
bool in_transaction
 

Detailed Description

The feature_recorder_set is an object that controls output. It knows where the output goes (outdir), the various feature recorders that write to that output, and provides for synchronization. It also has the factory method for new feature_recorders. Therefore if you want a different feature_recorder, this set should be subclassed as well.

Definition at line 28 of file feature_recorder_set.h.


The documentation for this class was generated from the following files: