aboutsummaryrefslogtreecommitdiff
path: root/example/reader_util.c
diff options
context:
space:
mode:
authorLuca Deri <deri@ntop.org>2024-11-28 23:19:25 +0100
committerLuca Deri <deri@ntop.org>2024-11-28 23:19:25 +0100
commit6b6b5c7c4e4e6112dcd6722a8685ee3517d7d5bc (patch)
tree118e9be6593bee4c7de0fa3481716d2eff3d59e1 /example/reader_util.c
parentb7405c8e3902b88a15ad0e3c2a019d97b56a6a81 (diff)
Enhanced STUN stats
Diffstat (limited to 'example/reader_util.c')
-rw-r--r--example/reader_util.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/example/reader_util.c b/example/reader_util.c
index e31dc0624..9a0e7dc64 100644
--- a/example/reader_util.c
+++ b/example/reader_util.c
@@ -1198,10 +1198,12 @@ static void process_ndpi_monitoring_info(struct ndpi_flow_info *flow) {
add_to_address_port_list(&flow->stun.peer_address, &flow->ndpi_flow->monit->protos.dtls_stun_rtp.peer_address);
add_to_address_port_list(&flow->stun.relayed_address, &flow->ndpi_flow->monit->protos.dtls_stun_rtp.relayed_address);
add_to_address_port_list(&flow->stun.response_origin, &flow->ndpi_flow->monit->protos.dtls_stun_rtp.response_origin);
-
+ flow->stun.num_mapped_address = flow->ndpi_flow->stun.num_mapped_address;
+ flow->stun.num_relayed_address = flow->ndpi_flow->stun.num_relayed_address;
+ flow->stun.num_non_stun_pkts = flow->ndpi_flow->stun.num_non_stun_pkts;
+ flow->stun.num_stun_transitions = flow->ndpi_flow->stun.num_stun_transitions;
flow->multimedia_flow_types |= flow->ndpi_flow->flow_multimedia_types;
}
-
}
/* ****************************************************** */
@@ -1607,6 +1609,10 @@ void process_ndpi_collected_info(struct ndpi_workflow * workflow, struct ndpi_fl
add_to_address_port_list(&flow->stun.relayed_address, &flow->ndpi_flow->stun.relayed_address);
add_to_address_port_list(&flow->stun.response_origin, &flow->ndpi_flow->stun.response_origin);
add_to_address_port_list(&flow->stun.other_address, &flow->ndpi_flow->stun.other_address);
+ flow->stun.num_mapped_address = flow->ndpi_flow->stun.num_mapped_address;
+ flow->stun.num_relayed_address = flow->ndpi_flow->stun.num_relayed_address;
+ flow->stun.num_non_stun_pkts = flow->ndpi_flow->stun.num_non_stun_pkts;
+ flow->stun.num_stun_transitions = flow->ndpi_flow->stun.num_stun_transitions;
}
flow->multimedia_flow_types |= flow->ndpi_flow->flow_multimedia_types;