aboutsummaryrefslogtreecommitdiff
path: root/src/lib/protocols/dns.c
diff options
context:
space:
mode:
authorLuca Deri <deri@ntop.org>2020-06-17 19:46:37 +0200
committerLuca Deri <deri@ntop.org>2020-06-17 19:46:37 +0200
commit46d96e7f32a799ae57400d82e4c485e4ef9771ab (patch)
tree9ac0add675d61a6653e5b59414e3672f1773e94f /src/lib/protocols/dns.c
parentffd20ebdf94beffc1cb8ec56896a86e28907702c (diff)
Added checks for DGA detection
Diffstat (limited to 'src/lib/protocols/dns.c')
-rw-r--r--src/lib/protocols/dns.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/protocols/dns.c b/src/lib/protocols/dns.c
index 099f343e4..897fb1e4b 100644
--- a/src/lib/protocols/dns.c
+++ b/src/lib/protocols/dns.c
@@ -294,11 +294,12 @@ static void ndpi_search_dns(struct ndpi_detection_module_struct *ndpi_struct, st
}
flow->host_server_name[j] = '\0';
- ndpi_check_dga_name(ndpi_struct, flow, (char*)flow->host_server_name);
if(j > 0) {
ndpi_protocol_match_result ret_match;
+ ndpi_check_dga_name(ndpi_struct, flow, (char*)flow->host_server_name);
+
ret.app_protocol = ndpi_match_host_subprotocol(ndpi_struct, flow,
(char *)flow->host_server_name,
strlen((const char*)flow->host_server_name),