Home
last modified time | relevance | path

Searched refs:dst_ip_country (Results 1 – 9 of 9) sorted by relevance

/dports/net-mgmt/pmacct/pmacct-1.7.5/src/
H A Dplugin_cmn_json.c850 if (cc->primitives.dst_ip_country.id > 0) in compose_json_dst_host_country()
851 …ew_nocheck(obj, "country_ip_dst", json_string(GeoIP_code_by_id(cc->primitives.dst_ip_country.id))); in compose_json_dst_host_country()
871 if (strlen(cc->primitives.dst_ip_country.str)) in compose_json_dst_host_country()
872 …json_object_set_new_nocheck(obj, "country_ip_dst", json_string(cc->primitives.dst_ip_country.str)); in compose_json_dst_host_country()
H A Dmongodb_plugin.c681 if (data->dst_ip_country.id > 0) in MongoDB_cache_purge()
682 bson_append_string(bson_elem, "country_ip_dst", GeoIP_code_by_id(data->dst_ip_country.id)); in MongoDB_cache_purge()
695 if (strlen(data->dst_ip_country.str)) in MongoDB_cache_purge()
696 bson_append_string(bson_elem, "country_ip_dst", data->dst_ip_country.str); in MongoDB_cache_purge()
H A Dplugin_cmn_avro.c739 if (pbase->dst_ip_country.id > 0) in compose_avro_acct_data()
740 pm_avro_check(avro_value_set_string(&field, GeoIP_code_by_id(pbase->dst_ip_country.id))); in compose_avro_acct_data()
756 if (strlen(pbase->dst_ip_country.str)) in compose_avro_acct_data()
757 pm_avro_check(avro_value_set_string(&field, pbase->dst_ip_country.str)); in compose_avro_acct_data()
H A Dserver.c540 …if (w2 & COUNT_DST_HOST_COUNTRY) memcpy(&d1->dst_ip_country, &s1->dst_ip_country, sizeof(d1->dst_i… in mask_elem()
H A Dpmacct.c1546 request.data.dst_ip_country.id = GeoIP_id_by_code(match_string_token); in main()
1554 strlcpy(request.data.dst_ip_country.str, match_string_token, PM_COUNTRY_T_STRLEN); in main()
2565 …_OUTPUT_FORMATTED) printf("%-5s ", GeoIP_code_by_id(acc_elem->primitives.dst_ip_country.id)); in main()
2566 …intf("%s%s", write_sep(sep_ptr, &count), GeoIP_code_by_id(acc_elem->primitives.dst_ip_country.id)); in main()
2576 …nt_output & PRINT_OUTPUT_FORMATTED) printf("%-5s ", acc_elem->primitives.dst_ip_country.str); in main()
2577 …NT_OUTPUT_CSV) printf("%s%s", write_sep(sep_ptr, &count), acc_elem->primitives.dst_ip_country.str); in main()
3508 if (pbase->dst_ip_country.id > 0) in pmc_compose_json()
3509 …ct_set_new_nocheck(obj, "country_ip_dst", json_string(GeoIP_code_by_id(pbase->dst_ip_country.id))); in pmc_compose_json()
3523 if (strlen(pbase->dst_ip_country.str)) in pmc_compose_json()
3524 json_object_set_new_nocheck(obj, "country_ip_dst", json_string(pbase->dst_ip_country.str)); in pmc_compose_json()
H A Dnetwork.h422 pm_country_t dst_ip_country; member
H A Dsql_handlers.c206 …LEFT(where_clause), where[num].string, GeoIP_code_by_id(cache_elem->primitives.dst_ip_country.id)); in count_dst_host_country_handler()
207 …FT(values_clause), values[num].string, GeoIP_code_by_id(cache_elem->primitives.dst_ip_country.id)); in count_dst_host_country_handler()
223 …*ptr_where, SPACELEFT(where_clause), where[num].string, cache_elem->primitives.dst_ip_country.str); in count_dst_host_country_handler()
224 …r_values, SPACELEFT(values_clause), values[num].string, cache_elem->primitives.dst_ip_country.str); in count_dst_host_country_handler()
H A Dprint_plugin.c707 …t_2 & COUNT_DST_HOST_COUNTRY) fprintf(f, "%-5s ", GeoIP_code_by_id(data->dst_ip_country.id)); in P_cache_purge()
711 …nfig.what_to_count_2 & COUNT_DST_HOST_COUNTRY) fprintf(f, "%-5s ", data->dst_ip_country.str); in P_cache_purge()
1095 …OST_COUNTRY) fprintf(f, "%s%s", write_sep(sep, &count), GeoIP_code_by_id(data->dst_ip_country.id)); in P_cache_purge()
1099 …t_2 & COUNT_DST_HOST_COUNTRY) fprintf(f, "%s%s", write_sep(sep, &count), data->dst_ip_country.str); in P_cache_purge()
H A Dpkt_handlers.c5373 pdata->primitives.dst_ip_country.id = 0; in dst_host_country_geoip_handler()
5377 …pdata->primitives.dst_ip_country.id = GeoIP_id_by_ipnum(config.geoip_ipv4, ntohl(((struct pm_iphdr… in dst_host_country_geoip_handler()
5382 …pdata->primitives.dst_ip_country.id = GeoIP_id_by_ipnum_v6(config.geoip_ipv6, ((struct ip6_hdr *)p… in dst_host_country_geoip_handler()
5525 … memcpy(pdata->primitives.dst_ip_country.str, entry_data_list->entry_data.utf8_string, size); in dst_host_country_geoipv2_handler()
5526 pdata->primitives.dst_ip_country.str[size] = '\0'; in dst_host_country_geoipv2_handler()
5535 strncpy(pdata->primitives.dst_ip_country.str, other_country, strlen(other_country)); in dst_host_country_geoipv2_handler()