diff options
author | Luca Deri <deri@ntop.org> | 2018-04-06 11:34:26 +0200 |
---|---|---|
committer | Luca Deri <deri@ntop.org> | 2018-04-06 11:34:26 +0200 |
commit | c7e53724dc097d81183d502804ed0642d64e16f9 (patch) | |
tree | 76e0a9e188ee564ba3acc298632914dcad656f5e | |
parent | 85f25fad6d49551914b18a3ee73a8547c44d8d81 (diff) |
Added protocol placeholders for undefined protocols
-rw-r--r-- | src/include/ndpi_protocol_ids.h | 8 | ||||
-rw-r--r-- | src/lib/ndpi_main.c | 12 |
2 files changed, 19 insertions, 1 deletions
diff --git a/src/include/ndpi_protocol_ids.h b/src/include/ndpi_protocol_ids.h index cc0132cd3..f92e580c3 100644 --- a/src/include/ndpi_protocol_ids.h +++ b/src/include/ndpi_protocol_ids.h @@ -86,7 +86,10 @@ #define NDPI_CONTENT_MMS 46 #define NDPI_PROTOCOL_XBOX 47 #define NDPI_PROTOCOL_QQ 48 + /* Free to use */ +#define NDPI_PROTOCOL_FREE_A 49 + #define NDPI_PROTOCOL_RTSP 50 #define NDPI_PROTOCOL_MAIL_IMAPS 51 #define NDPI_PROTOCOL_ICECAST 52 @@ -176,7 +179,10 @@ #define NDPI_PROTOCOL_YOUTUBE_UPLOAD 136 /* Upload files to youtube */ #define NDPI_PROTOCOL_ICQ 137 #define NDPI_PROTOCOL_CHECKMK 138 -/* Free */ + +/* Free to use */ +#define NDPI_PROTOCOL_FREE_B 139 + #define NDPI_PROTOCOL_APPLE 140 #define NDPI_PROTOCOL_WEBEX 141 #define NDPI_PROTOCOL_WHATSAPP 142 diff --git a/src/lib/ndpi_main.c b/src/lib/ndpi_main.c index 3b355436e..9d04f8630 100644 --- a/src/lib/ndpi_main.c +++ b/src/lib/ndpi_main.c @@ -1794,6 +1794,18 @@ static void ndpi_init_protocol_defaults(struct ndpi_detection_module_struct *ndp ndpi_build_default_ports(ports_a, 0, 0, 0, 0, 0) /* TCP */, ndpi_build_default_ports(ports_b, 0, 0, 0, 0, 0) /* UDP */); + /* To remove */ + ndpi_set_proto_defaults(ndpi_mod, NDPI_PROTOCOL_ACCEPTABLE, NDPI_PROTOCOL_FREE_A, + no_master, + no_master, "PlaceholderA", NDPI_PROTOCOL_CATEGORY_UNSPECIFIED, + ndpi_build_default_ports(ports_a, 0, 0, 0, 0, 0) /* TCP */, + ndpi_build_default_ports(ports_b, 0, 0, 0, 0, 0) /* UDP */); + ndpi_set_proto_defaults(ndpi_mod, NDPI_PROTOCOL_ACCEPTABLE, NDPI_PROTOCOL_FREE_B, + no_master, + no_master, "PlaceholderB", NDPI_PROTOCOL_CATEGORY_UNSPECIFIED, + ndpi_build_default_ports(ports_a, 0, 0, 0, 0, 0) /* TCP */, + ndpi_build_default_ports(ports_b, 0, 0, 0, 0, 0) /* UDP */); + /* calling function for host and content matched protocols */ init_string_based_protocols(ndpi_mod); |