From 6b8234d93803598ab98c26a7724ede6c5ea51bca Mon Sep 17 00:00:00 2001 From: Ravi Kerur Date: Sat, 9 Mar 2019 10:38:24 -0800 Subject: Xbox and PS4 static port classification. Signed-off-by: Ravi Kerur --- src/lib/protocols/xbox.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/lib/protocols/xbox.c') diff --git a/src/lib/protocols/xbox.c b/src/lib/protocols/xbox.c index 5d1f64d43..768bb7322 100644 --- a/src/lib/protocols/xbox.c +++ b/src/lib/protocols/xbox.c @@ -80,6 +80,11 @@ void ndpi_search_xbox(struct ndpi_detection_module_struct *ndpi_struct, struct n NDPI_LOG_DBG(ndpi_struct, "maybe xbox\n"); flow->l4.udp.xbox_stage++; return; + } else if ((dport == 3075 || dport == 3076 || dport == 3077 || dport == 3078) || + (sport == 3075 || sport == 3076 || sport == 3077 || sport == 3078)) { + ndpi_int_xbox_add_connection(ndpi_struct, flow); + NDPI_LOG_INFO(ndpi_struct, "found xbox udp port connection detected\n"); + return; } /* exclude here all non matched udp traffic, exclude here tcp only if http has been excluded, because xbox could use http */ @@ -96,7 +101,7 @@ void init_xbox_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int ndpi_set_bitmask_protocol_detection("Xbox", ndpi_struct, detection_bitmask, *id, NDPI_PROTOCOL_XBOX, ndpi_search_xbox, - NDPI_SELECTION_BITMASK_PROTOCOL_V4_V6_TCP_WITH_PAYLOAD, + NDPI_SELECTION_BITMASK_PROTOCOL_V4_V6_UDP_WITH_PAYLOAD, NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN, ADD_TO_DETECTION_BITMASK); -- cgit v1.2.3