h323: fix heap-overflow error

This commit is contained in:
Nardi Ivan
2020-03-27 11:09:53 +01:00
parent 58f0f29113
commit 45ff2a3f5a
+1 -1
View File
@@ -29,7 +29,7 @@ void ndpi_search_h323(struct ndpi_detection_module_struct *ndpi_struct, struct n
NDPI_LOG_DBG2(ndpi_struct, "calculated dport over tcp\n");
/* H323 */
if(packet->payload_packet_len >= 3
if(packet->payload_packet_len >= 4
&& (packet->payload[0] == 0x03)
&& (packet->payload[1] == 0x00)) {
struct tpkt *t = (struct tpkt*)packet->payload;