Skip to content

Commit a9c4dba

Browse files
catenacybervictorjulien
authored andcommitted
fuzz: use lower pcre limits
to avoid timeouts instead of forbidding pcre signatures on stream Ticket: 4858 (cherry picked from commit 7750226)
1 parent 38840c5 commit a9c4dba

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/detect-pcre.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,13 @@
3737

3838
#define DETECT_PCRE_CAPTURE_MAX 8
3939

40+
#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
41+
#define SC_MATCH_LIMIT_DEFAULT 350
42+
#define SC_MATCH_LIMIT_RECURSION_DEFAULT 150
43+
#else
4044
#define SC_MATCH_LIMIT_DEFAULT 3500
4145
#define SC_MATCH_LIMIT_RECURSION_DEFAULT 1500
46+
#endif
4247

4348
typedef struct DetectPcreData_ {
4449
/* pcre options */

0 commit comments

Comments
 (0)