Add a specific protocol id for audio/video calls made using Google apps (#2341)

Same logic already used for Signal/Whatsapp/Line/Facebook/...
This commit is contained in:
Ivan Nardi
2024-03-07 13:48:19 +01:00
committed by GitHub
parent c09b4dacdf
commit 56ce228a8b
9 changed files with 41 additions and 22 deletions
+4 -4
View File
@@ -274,7 +274,7 @@ int is_stun(struct ndpi_detection_module_struct *ndpi_struct,
NDPI_LOG_DBG(ndpi_struct, "Realm [%s]\n", flow->host_server_name);
if(strstr(flow->host_server_name, "google.com") != NULL) {
*app_proto = NDPI_PROTOCOL_GOOGLE_MEET;
*app_proto = NDPI_PROTOCOL_GOOGLE_CALL;
return 1;
} else if(strstr(flow->host_server_name, "whispersystems.org") != NULL ||
strstr(flow->host_server_name, "signal.org") != NULL) {
@@ -307,7 +307,7 @@ int is_stun(struct ndpi_detection_module_struct *ndpi_struct,
return 1;
case 0xFF03:
*app_proto = NDPI_PROTOCOL_GOOGLE_MEET;
*app_proto = NDPI_PROTOCOL_GOOGLE_CALL;
return 1;
case 0x0013:
@@ -578,7 +578,7 @@ static void ndpi_int_stun_add_connection(struct ndpi_detection_module_struct *nd
memcmp(flow->c_address.v6, &pref2, sizeof(pref2)) == 0 ||
memcmp(flow->s_address.v6, &pref1, sizeof(pref1)) == 0 ||
memcmp(flow->s_address.v6, &pref2, sizeof(pref2)) == 0) {
app_proto = NDPI_PROTOCOL_GOOGLE_MEET;
app_proto = NDPI_PROTOCOL_GOOGLE_CALL;
}
} else {
u_int32_t c_address, s_address;
@@ -589,7 +589,7 @@ static void ndpi_int_stun_add_connection(struct ndpi_detection_module_struct *nd
(c_address & 0xFFFFFF00) == 0x8efa5200 || /* 142.250.82.0/24 */
(s_address & 0xFFFFFF00) == 0x4a7dfa00 ||
(s_address & 0xFFFFFF00) == 0x8efa5200) {
app_proto = NDPI_PROTOCOL_GOOGLE_MEET;
app_proto = NDPI_PROTOCOL_GOOGLE_CALL;
}
}
}