diff options
author | Toni Uhlig <matzeton@googlemail.com> | 2021-07-13 17:41:05 +0200 |
---|---|---|
committer | Toni Uhlig <matzeton@googlemail.com> | 2021-07-13 20:36:19 +0200 |
commit | 278b0ca021022c5426687fba1d492e2899b58ab2 (patch) | |
tree | 5639fa0fc48925d4a2ab0976cf9d4de2aa8f0792 /src/lib/protocols/steam.c | |
parent | e4453938d5329daaa0ea682bba55d354759c077e (diff) |
Improved Steam detection (Steam Datagram Relay - SDR).improved/dnscrypt_and_steam
* improved DNSCrypt midstream detection again (sufficient for all tested use-cases)
Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
Diffstat (limited to 'src/lib/protocols/steam.c')
-rw-r--r-- | src/lib/protocols/steam.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/protocols/steam.c b/src/lib/protocols/steam.c index f6c0da425..8cd3ec41f 100644 --- a/src/lib/protocols/steam.c +++ b/src/lib/protocols/steam.c @@ -113,6 +113,15 @@ static void ndpi_check_steam_udp1(struct ndpi_detection_module_struct *ndpi_stru return; } + /* Check for Steam Datagram Relay (SDR) packets. */ + if (payload_len > 8 && + ndpi_ntohll(get_u_int64_t(packet->payload, 0)) == 0x0101736470696e67 /* "\x01\x01sdping" */) + { + NDPI_LOG_INFO(ndpi_struct, "found STEAM (Steam Datagram Relay)\n"); + ndpi_int_steam_add_connection(ndpi_struct, flow); + return; + } + /* Check if we so far detected the protocol in the request or not. */ if (flow->steam_stage1 == 0) { NDPI_LOG_DBG2(ndpi_struct, "STEAM stage 0: \n"); |