config: allow configuration of guessing algorithms
This commit is contained in:
@@ -290,14 +290,12 @@ extern "C" {
|
||||
*
|
||||
* @par ndpi_struct = the detection module
|
||||
* @par flow = the flow given for the detection module
|
||||
* @par enable_guess = guess protocol if unknown
|
||||
* @par protocol_was_guessed = 1 if the protocol was guesses (requires enable_guess = 1), 0 otherwise
|
||||
* @return the detected protocol even if the flow is not completed;
|
||||
*
|
||||
*/
|
||||
ndpi_protocol ndpi_detection_giveup(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct ndpi_flow_struct *flow,
|
||||
u_int8_t enable_guess,
|
||||
u_int8_t *protocol_was_guessed);
|
||||
|
||||
/**
|
||||
|
||||
@@ -167,6 +167,7 @@ struct ndpi_detection_module_config_struct {
|
||||
int fully_encrypted_heuristic;
|
||||
int track_payload_enabled;
|
||||
int libgcrypt_init;
|
||||
int guess_on_giveup;
|
||||
|
||||
char filename_config[CFG_MAX_LEN];
|
||||
|
||||
|
||||
@@ -761,6 +761,8 @@ struct ndpi_lru_cache {
|
||||
struct ndpi_lru_cache_entry *entries;
|
||||
};
|
||||
|
||||
#define NDPI_GIVEUP_GUESS_BY_PORT 0x01
|
||||
#define NDPI_GIVEUP_GUESS_BY_IP 0x02
|
||||
|
||||
/* Aggressiveness values */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user