TSG-19907 Proxy日志中ASN字段填写错误,只需填写ASNUMER

This commit is contained in:
fengweihao
2024-03-14 16:32:09 +08:00
parent eed2929927
commit fc17f73bff

View File

@@ -222,7 +222,7 @@ int tfe_scan_ip_asn(const struct tfe_stream *stream, long long *result, struct m
hit_cnt_ip += n_hit_result; hit_cnt_ip += n_hit_result;
} }
memset(buff, 0, sizeof(buff)); memset(buff, 0, sizeof(buff));
snprintf(buff, sizeof(buff), "%s(%s)", dst_asn, dst_org); snprintf(buff, sizeof(buff), "%s", dst_asn);
*asn_server = tfe_strdup(buff); *asn_server = tfe_strdup(buff);
} }
if (strlen(src_asn)) if (strlen(src_asn))
@@ -248,7 +248,7 @@ int tfe_scan_ip_asn(const struct tfe_stream *stream, long long *result, struct m
hit_cnt_ip += n_hit_result; hit_cnt_ip += n_hit_result;
} }
memset(buff, 0, sizeof(buff)); memset(buff, 0, sizeof(buff));
snprintf(buff, sizeof(buff), "%s(%s)", src_asn, src_org); snprintf(buff, sizeof(buff), "%s", src_asn);
*asn_client = tfe_strdup(buff); *asn_client = tfe_strdup(buff);
} }
return hit_cnt_ip; return hit_cnt_ip;