Added ability to report whether a protocol is encrypted
Added new API calls - u_int8_t ndpi_is_valid_protoId(u_int16_t protoId); Cleaned up code and organized in a function. - u_int8_t ndpi_is_encrypted_proto(struct ndpi_detection_module_struct *ndpi_str, ndpi_protocol proto); Check whether a protocol is encrypted or not based on master and app protocols
This commit is contained in:
committed by
Simone Mainardi
parent
b8806bd2de
commit
dabab0e951
@@ -1054,7 +1054,9 @@ extern "C" {
|
||||
/* General purpose utilities */
|
||||
u_int64_t ndpi_htonll(u_int64_t v);
|
||||
u_int64_t ndpi_ntohll(u_int64_t v);
|
||||
|
||||
u_int8_t ndpi_is_valid_protoId(u_int16_t protoId);
|
||||
u_int8_t ndpi_is_encrypted_proto(struct ndpi_detection_module_struct *ndpi_str, ndpi_protocol proto);
|
||||
|
||||
/* DGA */
|
||||
int ndpi_check_dga_name(struct ndpi_detection_module_struct *ndpi_str,
|
||||
struct ndpi_flow_struct *flow,
|
||||
|
||||
@@ -103,6 +103,7 @@ extern "C" {
|
||||
int protoId, ...);
|
||||
|
||||
extern void ndpi_set_proto_defaults(struct ndpi_detection_module_struct *ndpi_mod,
|
||||
u_int8_t is_cleartext,
|
||||
ndpi_protocol_breed_t protoBreed, u_int16_t protoId, char *protoName,
|
||||
ndpi_protocol_category_t protoCategory,
|
||||
ndpi_port_range *tcpDefPorts,
|
||||
|
||||
@@ -1046,7 +1046,8 @@ typedef enum {
|
||||
typedef struct ndpi_proto_defaults {
|
||||
char *protoName;
|
||||
ndpi_protocol_category_t protoCategory;
|
||||
u_int16_t * subprotocols;
|
||||
u_int8_t isClearTextProto;
|
||||
u_int16_t *subprotocols;
|
||||
u_int32_t subprotocol_count;
|
||||
u_int16_t protoId, protoIdx;
|
||||
u_int16_t tcp_default_ports[MAX_DEFAULT_PORTS], udp_default_ports[MAX_DEFAULT_PORTS];
|
||||
|
||||
Reference in New Issue
Block a user