2 Star 6 Fork 3

qazxlf / NetSurveyW

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
survey.h 1.23 KB
一键复制 编辑 原始数据 按行查看 历史
#pragma once
#include <iostream>
#include <fstream>
#include "httpauditor.h"
#include "httpcaptor.h"
#include <ace/Thread_Manager.h>
#include "ace/Log_Msg.h"
#include "ace/Reactor.h"
#include <string.h>
#include "ffcs_logger.h"
#include "my_ringbuffbased_fifo.h"
#include "msgdefine.h"
#include "Pcre.h"
#include "offlinecaptor.h"
class survey
{
public:
survey(void);
~survey(void);
int create();
int load_config();
int run();
int stop();
int reset();
int run_offline(const char* file);
int stop_offline();
void register_callback(SESSION_CALLBACK p);
void register_interaction_callback(INTERACTION_CALLBACK p);
int add_rule(const std::string &name, const std::string &patten);
void clear_rule();
std::vector<MatchResult> run_regex(const char source[]);
inline Logger& get_logger(){
return _log;
}
inline bool is_running()const{
return _run_flag;
}
inline bool set_dumpfilepath(const char* path){
if(_captor){
_captor->set_dumpfilepath(path);
return true;
}
return false;
}
private:
int destroy();
static void process_usr_quit(void* args);
private:
Logger _log;
httpcaptor* _captor;
httpauditor* _auditor;
offlinecaptor* _off_captor;
my_fifo<tcp_connection_info >* _ringfifo;
Pcre _pcre;
int _run_flag;
};
C++
1
https://gitee.com/xulongfei0612/NetSurveyW.git
git@gitee.com:xulongfei0612/NetSurveyW.git
xulongfei0612
NetSurveyW
NetSurveyW
master

搜索帮助