Added memory boundary checks
This commit is contained in:
+2
-1
@@ -4858,7 +4858,8 @@ void ndpi_parse_packet_line_info(struct ndpi_detection_module_struct *ndpi_str,
|
||||
if(get_u_int16_t(packet->payload, a) == ntohs(0x0d0a)) {
|
||||
/* If end of line char sequence CR+NL "\r\n", process line */
|
||||
|
||||
if(get_u_int16_t(packet->payload, a+2) == ntohs(0x0d0a)) {
|
||||
if(((a + 3) <= packet->payload_packet_len)
|
||||
&& (get_u_int16_t(packet->payload, a+2) == ntohs(0x0d0a))) {
|
||||
/* \r\n\r\n */
|
||||
int diff; /* No unsigned ! */
|
||||
u_int32_t a1 = a + 4;
|
||||
|
||||
Reference in New Issue
Block a user