去除中文注释
This commit is contained in:
@@ -4,9 +4,9 @@
|
||||
extern int g_iThreadNum;
|
||||
|
||||
|
||||
/* 关于没有命中配置情况下的默认配置
|
||||
1. g_maat_default_action: 读配置文件, policy_id = 0
|
||||
2. 如果maat的编译配置表中有policy_id = 0的配置,则将 g_maat_default_action设为对应的action, policy_id = 0
|
||||
/* default action:
|
||||
1. read kni.conf
|
||||
2. compile_id = 0
|
||||
*/
|
||||
|
||||
enum kni_action g_maat_default_action;
|
||||
@@ -30,7 +30,7 @@ void kni_maat_destroy(struct kni_maat_handle *handle){
|
||||
|
||||
void compile_ex_param_new(int idx, const struct Maat_rule_t* rule, const char* srv_def_large, MAAT_RULE_EX_DATA* ad, long argl, void *argp){
|
||||
void *logger = argp;
|
||||
KNI_LOG_DEBUG(logger, "call compile_ex_param_new");
|
||||
KNI_LOG_INFO(logger, "call compile_ex_param_new");
|
||||
if(rule->config_id == 0){
|
||||
g_maat_default_action = (enum kni_action)rule->action;
|
||||
}
|
||||
@@ -39,13 +39,13 @@ void compile_ex_param_new(int idx, const struct Maat_rule_t* rule, const char* s
|
||||
|
||||
void compile_ex_param_free(int idx, const struct Maat_rule_t* rule, const char* srv_def_large, MAAT_RULE_EX_DATA* ad, long argl, void *argp){
|
||||
void *logger = argp;
|
||||
KNI_LOG_DEBUG(logger, "call compile_ex_param_free");
|
||||
KNI_LOG_INFO(logger, "call compile_ex_param_free");
|
||||
return;
|
||||
}
|
||||
|
||||
void compile_ex_param_dup(int idx, MAAT_RULE_EX_DATA *to, MAAT_RULE_EX_DATA *from, long argl, void *argp){
|
||||
void *logger = argp;
|
||||
KNI_LOG_DEBUG(logger, "call compile_ex_param_dup");
|
||||
KNI_LOG_INFO(logger, "call compile_ex_param_dup");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -203,8 +203,8 @@ enum kni_action intercept_policy_scan(struct kni_maat_handle* handle, struct ipa
|
||||
struct Maat_rule_t result[KNI_MAAT_RULE_NUM_MAX];
|
||||
scan_status_t scan_mid = NULL;
|
||||
int scan_ret=0, hit_policy_cnt=0, enforced_policy_idx=0;
|
||||
|
||||
scan_ret = Maat_scan_proto_addr(maat_feather, table_intercept_ip, addr, 0,
|
||||
//tcp: 6, udp: 17, can't be 0
|
||||
scan_ret = Maat_scan_proto_addr(maat_feather, table_intercept_ip, addr, 6,
|
||||
result+hit_policy_cnt, KNI_MAAT_RULE_NUM_MAX-hit_policy_cnt,
|
||||
&scan_mid, thread_seq);
|
||||
if(scan_ret>0)
|
||||
|
||||
Reference in New Issue
Block a user