Adds different checks against overflows

This commit is contained in:
Philippe Antoine
2020-03-19 16:54:31 +01:00
parent e9195589d2
commit c6acf97bfb
4 changed files with 7 additions and 2 deletions
+1 -1
View File
@@ -33,7 +33,7 @@ void ndpi_search_fix(struct ndpi_detection_module_struct *ndpi_struct, struct nd
struct ndpi_packet_struct *packet = &flow->packet;
NDPI_LOG_DBG(ndpi_struct, "search FIX\n");
if(packet->tcp) {
if(packet->tcp && packet->payload_packet_len > 5) {
// 8=
if(packet->payload[0] == 0x38 && packet->payload[1] == 0x3d) {
// FIX.