From a1ac31062df98a651f2d6fee8bd3fe66e7734f6a Mon Sep 17 00:00:00 2001 From: Luca Deri Date: Sun, 30 Jun 2019 11:59:51 +0200 Subject: Added ndpi_has_human_readeable_string for detecting human-readeable strings in buffers --- example/ndpiReader.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'example') diff --git a/example/ndpiReader.c b/example/ndpiReader.c index 2a2f1cbf5..6351ce034 100644 --- a/example/ndpiReader.c +++ b/example/ndpiReader.c @@ -2474,6 +2474,8 @@ static void ndpi_process_packet(u_char *args, /* allocate an exact size buffer to check overflows */ uint8_t *packet_checked = malloc(header->caplen); + /* ndpi_has_human_readeable_string(ndpi_info_mod, (char*)packet, header->caplen, 3); */ + memcpy(packet_checked, packet, header->caplen); p = ndpi_workflow_process_packet(ndpi_thread_info[thread_id].workflow, header, packet_checked); -- cgit v1.2.3