http1: set all events in a flow

Do not put a limit to set only the first 512 events

Ticket: 8867
pull/16213/head
Philippe Antoine 2 months ago committed by Victor Julien
parent fefe0a9b8b
commit 1ce0e303e7

@ -640,8 +640,7 @@ static uint32_t AppLayerHtpComputeChunkLength(uint64_t content_len_so_far, uint3
*/
static void HTPHandleError(HtpState *s, const uint8_t dir)
{
if (s == NULL || s->conn == NULL || s->htp_messages_count >= HTP_MAX_MESSAGES) {
// ignore further messages
if (s == NULL || s->conn == NULL) {
return;
}
@ -663,12 +662,9 @@ static void HTPHandleError(HtpState *s, const uint8_t dir)
htp_free_cstring(msg);
htp_log_free(log);
s->htp_messages_count++;
if (s->htp_messages_count >= HTP_MAX_MESSAGES) {
if (s->htp_messages_count == HTP_MAX_MESSAGES) {
// only once per HtpState
HTPSetEvent(s, NULL, dir, HTTP_DECODER_EVENT_TOO_MANY_WARNINGS);
// too noisy in fuzzing
// DEBUG_VALIDATE_BUG_ON("Too many libhtp messages");
break;
}
log = htp_conn_next_log(s->conn);
}

Loading…
Cancel
Save