aboutsummaryrefslogtreecommitdiff
path: root/src/lib/protocols/http.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/protocols/http.c')
-rw-r--r--src/lib/protocols/http.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/protocols/http.c b/src/lib/protocols/http.c
index c57ed8441..bf365c46f 100644
--- a/src/lib/protocols/http.c
+++ b/src/lib/protocols/http.c
@@ -489,6 +489,15 @@ static void ndpi_http_parse_subprotocol(struct ndpi_detection_module_struct *ndp
ndpi_set_detected_protocol(ndpi_struct, flow, NDPI_PROTOCOL_OCSP, master_protocol, NDPI_CONFIDENCE_DPI);
}
+ /* HTTP Live Streaming */
+ if (packet->content_line.len > 28 &&
+ (strncmp((const char *)packet->content_line.ptr, "application/vnd.apple.mpegurl", 29) == 0 ||
+ strncmp((const char *)packet->content_line.ptr, "application/x-mpegURL", 21) == 0 ||
+ strncmp((const char *)packet->content_line.ptr, "application/x-mpegurl", 21) == 0)) {
+ NDPI_LOG_DBG2(ndpi_struct, "Found HLS\n");
+ ndpi_set_detected_protocol(ndpi_struct, flow, NDPI_PROTOCOL_HLS, master_protocol, NDPI_CONFIDENCE_DPI);
+ }
+
if((flow->http.method == NDPI_HTTP_METHOD_RPC_CONNECT) ||
(flow->http.method == NDPI_HTTP_METHOD_RPC_IN_DATA) ||
(flow->http.method == NDPI_HTTP_METHOD_RPC_OUT_DATA)) {