Introduced custom protocols with IP and (optional) port support
Example - Single IP address ip:213.75.170.11@CustomProtocol - IP address with CIDR ip:213.75.170.11/32@CustomProtocol - IP address with CIDR and port ip:213.75.170.11/32:443@CustomProtocol Please note that there are some restrictions on the port usage. They have been listed in example/protos.txt
This commit is contained in:
@@ -145,6 +145,21 @@ extern "C" {
|
||||
u_int16_t ndpi_network_ptree_match(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct in_addr *pin);
|
||||
|
||||
/**
|
||||
* Returns the nDPI protocol id for IP+port-based protocol detection
|
||||
*
|
||||
* @par ndpi_struct = the struct created for the protocol detection
|
||||
* @par pin = IP host address (MUST BE in network byte order):
|
||||
* See man(7) ip for details
|
||||
* @par port = The port (MUST BE in network byte order) or
|
||||
* 0 if ignored
|
||||
* @return the nDPI protocol ID
|
||||
*
|
||||
*/
|
||||
u_int16_t ndpi_network_port_ptree_match(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct in_addr *pin /* network byte order */,
|
||||
u_int16_t port /* network byte order */);
|
||||
|
||||
/**
|
||||
* Init single protocol match
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user