diff options
author | Luca Deri <deri@ntop.org> | 2019-09-29 21:46:41 +0200 |
---|---|---|
committer | Luca Deri <deri@ntop.org> | 2019-09-29 21:46:41 +0200 |
commit | f2a5bbef173ee7f5447871f26024b9639735c096 (patch) | |
tree | 1607ba80cf3b27968e0f710a4552a3f959ea58b2 /src/include/ndpi_api.h | |
parent | 016d568c2b073339e97bdf44e00a702845fa935e (diff) |
Reworked categories handling
Removed GenericProtocol and replaced with categories
Removed ndpi_pref_enable_category_substring_match option: substring matching is now default
Diffstat (limited to 'src/include/ndpi_api.h')
-rw-r--r-- | src/include/ndpi_api.h | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/src/include/ndpi_api.h b/src/include/ndpi_api.h index 34b1fed67..194afa7d6 100644 --- a/src/include/ndpi_api.h +++ b/src/include/ndpi_api.h @@ -383,13 +383,12 @@ extern "C" { * @return the ID of the matched subprotocol * */ - int ndpi_match_host_subprotocol(struct ndpi_detection_module_struct *ndpi_struct, - struct ndpi_flow_struct *flow, - char *string_to_match, - u_int string_to_match_len, - ndpi_protocol_match_result *ret_match, - u_int16_t master_protocol_id); - + u_int16_t ndpi_match_host_subprotocol(struct ndpi_detection_module_struct *ndpi_struct, + struct ndpi_flow_struct *flow, + char *string_to_match, + u_int string_to_match_len, + ndpi_protocol_match_result *ret_match, + u_int16_t master_protocol_id); /** * Check if the string content passed match with a protocol @@ -403,12 +402,12 @@ extern "C" { * @return the ID of the matched subprotocol * */ - int ndpi_match_content_subprotocol(struct ndpi_detection_module_struct *ndpi_struct, - struct ndpi_flow_struct *flow, - char *string_to_match, - u_int string_to_match_len, - ndpi_protocol_match_result *ret_match, - u_int16_t master_protocol_id); + u_int16_t ndpi_match_content_subprotocol(struct ndpi_detection_module_struct *ndpi_struct, + struct ndpi_flow_struct *flow, + char *string_to_match, + u_int string_to_match_len, + ndpi_protocol_match_result *ret_match, + u_int16_t master_protocol_id); /** * Exclude protocol from search * @@ -755,7 +754,7 @@ extern "C" { u_int32_t daddr, ndpi_protocol *ret); int ndpi_match_custom_category(struct ndpi_detection_module_struct *ndpi_struct, - char *name, unsigned long *id); + char *name, unsigned long *id); void ndpi_fill_protocol_category(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow, ndpi_protocol *ret); |