Project

General

Profile

Actions

Bug #4553

open

Configuration test mode succeeds when reference.config file contains invalid content

Added by Jeff Lucovsky over 3 years ago. Updated 6 months ago.

Status:
New
Priority:
Normal
Assignee:
Target version:
Affected Versions:
Effort:
Difficulty:
Label:

Description

Configuration test mode succeeds even when reference.config has invalid content:

$ echo "this is invalid" > reference.config
jlucovsky@ ~/src/jal/suricata (master) $ suricata -T -c suricata.yaml -S ~/rules/be.rule
[279195] 3/7/2021 -- 08:24:24 - (suricata.c:1615) <Info> (ParseCommandLine) -- Running suricata under test mode
[279195] 3/7/2021 -- 08:24:24 - (suricata.c:1059) <Notice> (LogVersion) -- This is Suricata version 7.0.0-dev (fb6246b26 2021-06-02) running in SYSTEM mode
[279195] 3/7/2021 -- 08:24:24 - (util-reference-config.c:247) <Error> (SCRConfAddReference) -- [ERRCODE: SC_ERR_REFERENCE_CONFIG(175)] - Invalid Reference Config in reference.config file
[279195] 3/7/2021 -- 08:24:25 - (suricata.c:2782) <Notice> (SuricataMain) -- Configuration provided was successfully loaded. Exiting.
jlucovsky@ ~/src/jal/suricata (master) $ echo $?
0

The expected behavior is to have a return code of 1 for the last step.


Related issues 2 (0 open2 closed)

Related to Suricata - Bug #4554: Configuration test mode succeeds when classification.config file contains invalid contentClosedJeff LucovskyActions
Related to Suricata - Bug #4369: Configuration test mode succeeds when threshold.config file contains invalid contentClosedJeff LucovskyActions
Actions #1

Updated by Jeff Lucovsky over 3 years ago

  • Related to Bug #4554: Configuration test mode succeeds when classification.config file contains invalid content added
Actions #2

Updated by Jeff Lucovsky over 3 years ago

  • Related to Bug #4369: Configuration test mode succeeds when threshold.config file contains invalid content added
Actions #3

Updated by Juliana Fajardini Reichow almost 2 years ago

I think what is reported in this post https://forum.suricata.io/t/detect-invalid-configuration/3229/1
goes along similar lines, but I couldn't find a ticket for the suricata.yaml file.

Actions #4

Updated by Philippe Antoine 6 months ago

  • Target version set to TBD
Actions #5

Updated by Philippe Antoine 6 months ago

  • Assignee set to OISF Dev
Actions

Also available in: Atom PDF