From b2bc6039da3b75a1537013c978d5779fd9109a5e Mon Sep 17 00:00:00 2001 From: Luca Date: Tue, 29 Aug 2017 21:32:52 +0200 Subject: Partial fix for #410: added case insensitive HTTP header checks. If the user will provide a pcap for reproducing further potential issues reported we will consider them --- src/include/ndpi_api.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/include/ndpi_api.h') diff --git a/src/include/ndpi_api.h b/src/include/ndpi_api.h index 03a73d66b..76285cb70 100644 --- a/src/include/ndpi_api.h +++ b/src/include/ndpi_api.h @@ -98,6 +98,18 @@ extern "C" { */ char* ndpi_strnstr(const char *s, const char *find, size_t slen); + /** + * Same as ndpi_strnstr but case insensitive + * + * @par s = string to parse + * @par find = string to match with -s- + * @par slen = max length to match between -s- and -find- + * @return a pointer to the beginning of the located substring; + * NULL if the substring is not found + * + */ + char* ndpi_strncasestr(const char *s, const char *find, size_t slen); + /** * Returns the nDPI protocol id for IP-based protocol detection -- cgit v1.2.3