From: Victor Julien Date: Sat, 23 Sep 2023 05:43:54 +0000 (+0200) Subject: detect-engine: minor content inspection cleanup X-Git-Tag: suricata-8.0.0-beta1~2020 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ee66a7246fc2db41c53d1934e2f515dabf725bf4;p=thirdparty%2Fsuricata.git detect-engine: minor content inspection cleanup --- diff --git a/src/detect-engine.c b/src/detect-engine.c index 4cf145df6e..c078b824d0 100644 --- a/src/detect-engine.c +++ b/src/detect-engine.c @@ -2257,10 +2257,6 @@ int DetectEngineInspectPktBufferGeneric( return DETECT_ENGINE_INSPECT_SIG_NO_MATCH; } - const uint32_t data_len = buffer->inspect_len; - const uint8_t *data = buffer->inspect; - const uint64_t offset = 0; - uint8_t ci_flags = DETECT_CI_FLAGS_START|DETECT_CI_FLAGS_END; ci_flags |= buffer->flags; @@ -2270,11 +2266,9 @@ int DetectEngineInspectPktBufferGeneric( /* Inspect all the uricontents fetched on each * transaction at the app layer */ - int r = DetectEngineContentInspection(det_ctx->de_ctx, det_ctx, - s, engine->smd, - p, p->flow, - (uint8_t *)data, data_len, offset, ci_flags, - DETECT_ENGINE_CONTENT_INSPECTION_MODE_HEADER); + int r = DetectEngineContentInspection(det_ctx->de_ctx, det_ctx, s, engine->smd, p, p->flow, + buffer->inspect, buffer->inspect_len, 0, ci_flags, + DETECT_ENGINE_CONTENT_INSPECTION_MODE_HEADER); if (r == 1) { return DETECT_ENGINE_INSPECT_SIG_MATCH; } else {