From: Philippe Antoine Date: Thu, 4 Jan 2024 10:42:55 +0000 (+0100) Subject: detect: case-insensitive comparison for requires X-Git-Tag: suricata-7.0.3~20 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=08dae404522e4c8bc8f87fee55756c9d814e207b;p=thirdparty%2Fsuricata.git detect: case-insensitive comparison for requires Ticket: 6656 (cherry picked from commit d3218385e942a4a01f3938f0cd7050f5dc7c9a6f) --- diff --git a/src/detect-parse.c b/src/detect-parse.c index a25d63ed59..78fecb4fdc 100644 --- a/src/detect-parse.c +++ b/src/detect-parse.c @@ -897,7 +897,7 @@ static int SigParseOptions(DetectEngineCtx *de_ctx, Signature *s, char *optstr, /* Check for options that are only to be processed during the * first "requires" pass. */ - bool requires_only = strcmp(optname, "requires") == 0 || strcmp(optname, "sid") == 0; + bool requires_only = strcasecmp(optname, "requires") == 0 || strcasecmp(optname, "sid") == 0; if ((requires && !requires_only) || (!requires && requires_only)) { goto finish; }