Function ndpi_match_host_subprotocol

Function Documentation

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, int update_flow_classification)

Check if the host passed match with a protocol

ndpi_struct = the detection module

flow = the flow where match the host

string_to_match = the string to match

string_to_match_len = the length of the string

ret_match = completed returned match information

master_protocol_id = value of the ID associated to the master protocol detected

update_flow_classification = update or not protocol (sub)classification

Returns:

the ID of the matched subprotocol