Reworked protocol handling chnging it is u_int16_t
This commit is contained in:
+2
-2
@@ -17,6 +17,6 @@ host:"api-global.netflix.com"@Netflix
|
|||||||
# Format:
|
# Format:
|
||||||
# ip:<value>,ip:<value>,.....@<subproto>
|
# ip:<value>,ip:<value>,.....@<subproto>
|
||||||
|
|
||||||
ip:213.75.170.11@CustomProtocol
|
ip:213.75.170.11/32:443@CustomProtocol
|
||||||
ip:8.248.73.247@AmazonPrime
|
ip:8.248.73.247:443@AmazonPrime
|
||||||
ip:54.80.47.130@AmazonPrime
|
ip:54.80.47.130@AmazonPrime
|
||||||
|
|||||||
@@ -803,12 +803,12 @@ extern "C" {
|
|||||||
u_int32_t daddr,
|
u_int32_t daddr,
|
||||||
ndpi_protocol *ret);
|
ndpi_protocol *ret);
|
||||||
int ndpi_match_custom_category(struct ndpi_detection_module_struct *ndpi_struct,
|
int ndpi_match_custom_category(struct ndpi_detection_module_struct *ndpi_struct,
|
||||||
char *name, u_int name_len, unsigned long *id);
|
char *name, u_int name_len, u_int16_t *id);
|
||||||
void ndpi_fill_protocol_category(struct ndpi_detection_module_struct *ndpi_struct,
|
void ndpi_fill_protocol_category(struct ndpi_detection_module_struct *ndpi_struct,
|
||||||
struct ndpi_flow_struct *flow,
|
struct ndpi_flow_struct *flow,
|
||||||
ndpi_protocol *ret);
|
ndpi_protocol *ret);
|
||||||
int ndpi_get_custom_category_match(struct ndpi_detection_module_struct *ndpi_struct,
|
int ndpi_get_custom_category_match(struct ndpi_detection_module_struct *ndpi_struct,
|
||||||
char *name_or_ip, u_int name_len, unsigned long *id);
|
char *name_or_ip, u_int name_len, u_int16_t *id);
|
||||||
int ndpi_set_detection_preferences(struct ndpi_detection_module_struct *ndpi_mod,
|
int ndpi_set_detection_preferences(struct ndpi_detection_module_struct *ndpi_mod,
|
||||||
ndpi_detection_preference pref,
|
ndpi_detection_preference pref,
|
||||||
int value);
|
int value);
|
||||||
@@ -840,7 +840,7 @@ extern "C" {
|
|||||||
* @return 0 in case of match, or -1 if no match, or -2 if an error occurred.
|
* @return 0 in case of match, or -1 if no match, or -2 if an error occurred.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
int ndpi_match_string_id(void *_automa, char *string_to_match, u_int match_len, unsigned long *id);
|
int ndpi_match_string_id(void *_automa, char *string_to_match, u_int match_len, u_int16_t *id);
|
||||||
|
|
||||||
/* Utility functions to set ndpi malloc/free/print wrappers */
|
/* Utility functions to set ndpi malloc/free/print wrappers */
|
||||||
void set_ndpi_malloc(void* (*__ndpi_malloc)(size_t size));
|
void set_ndpi_malloc(void* (*__ndpi_malloc)(size_t size));
|
||||||
|
|||||||
+4611
-4744
File diff suppressed because it is too large
Load Diff
+4
-1
@@ -102,7 +102,10 @@ typedef struct the_prefix_t {
|
|||||||
/* pointer to usr data (ex. route flap info) */
|
/* pointer to usr data (ex. route flap info) */
|
||||||
union patricia_node_value_t {
|
union patricia_node_value_t {
|
||||||
void *user_data;
|
void *user_data;
|
||||||
unsigned int user_value;
|
|
||||||
|
/* User-defined values */
|
||||||
|
u_int16_t user_value;
|
||||||
|
u_int16_t user_value2;
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef struct _patricia_node_t {
|
typedef struct _patricia_node_t {
|
||||||
|
|||||||
Reference in New Issue
Block a user