From 7c7c375b451ba506134f426f71e065c66c9200dc Mon Sep 17 00:00:00 2001 From: Luca Date: Wed, 12 Jun 2024 10:55:07 +0200 Subject: Improved detection of Android connectiity checks --- src/lib/protocols/http.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src') diff --git a/src/lib/protocols/http.c b/src/lib/protocols/http.c index c73bd47fe..bfb47f514 100644 --- a/src/lib/protocols/http.c +++ b/src/lib/protocols/http.c @@ -550,6 +550,16 @@ static void ndpi_http_parse_subprotocol(struct ndpi_detection_module_struct *ndp } } + if(flow->http.url + && ( + ends_with(ndpi_struct, (char*)flow->http.url, "/generate_204") + || ends_with(ndpi_struct, (char*)flow->http.url, "/generate204") + ) + ) { + flow->category = NDPI_PROTOCOL_CATEGORY_CONNECTIVITY_CHECK; + return; + } + if(flow->detected_protocol_stack[1] == NDPI_PROTOCOL_UNKNOWN && flow->http.url && ((strstr(flow->http.url, ":8080/downloading?n=0.") != NULL) || -- cgit v1.2.3