Actions
Bug #4677
closedConfiguration test mode succeeds when reference.config file contains invalid content
Description
When testing configuration settings (-T), invalid content in reference.config
doesn't result in the "test" failing.
If reference.config
contains
this is not correct
then
$ src/suricata -c suricata.yaml -T --set reference-config-file=reference.config -S ~/rules/be.rule [1607765] 2/9/2021 -- 13:51:11 - (suricata.c:1683) <Info> (ParseCommandLine) -- Running suricata under test mode [1607765] 2/9/2021 -- 13:51:11 - (suricata.c:1091) <Notice> (LogVersion) -- This is Suricata version 7.0.0-dev (148277ec9 2021-07-20) running in SYSTEM mode [1607765] 2/9/2021 -- 13:51:12 - (util-reference-config.c:247) <Error> (SCRConfAddReference) -- [ERRCODE: SC_ERR_REFERENCE_CONFIG(175)] - Invalid Reference Config in reference.config file [1607765] 2/9/2021 -- 13:51:12 - (suricata.c:2850) <Notice> (SuricataMain) -- Configuration provided was successfully loaded. Exiting. $ echo $? 0
Expected behavior:
jlucovsky@ ~/src/jal/suricata (master) $ src/suricata -c suricata.yaml -T --set reference-config-file=reference.config -S ~/rules/be.rule [1607765] 2/9/2021 -- 13:51:11 - (suricata.c:1683) <Info> (ParseCommandLine) -- Running suricata under test mode [1607765] 2/9/2021 -- 13:51:11 - (suricata.c:1091) <Notice> (LogVersion) -- This is Suricata version 7.0.0-dev (148277ec9 2021-07-20) running in SYSTEM mode [1607765] 2/9/2021 -- 13:51:12 - (util-reference-config.c:247) <Error> (SCRConfAddReference) -- [ERRCODE: SC_ERR_REFERENCE_CONFIG(175)] - Invalid Reference Config in reference.config file [1607765] 2/9/2021 -- 08:39:15 - (util-threshold-config.c:257) <Warning> (tbd) -- [ERRCODE: SC_WARN_REFERENCE_CONFIG(338)] - Error loading reference configuration from /tmp/reference.config [1607765] 2/9/2021 -- 08:39:15 - (suricata.c:2187) <Error> (LoadSignatures) -- [ERRCODE: SC_ERR_NO_RULES_LOADED(43)] - Loading signatures failed $ echo $? 1
Updated by Jeff Lucovsky over 3 years ago
- Copied from Bug #4659: Configuration test mode succeeds when reference.config file contains invalid content added
Updated by Victor Julien about 3 years ago
- Target version changed from 6.0.4 to 6.0.5
Updated by Shivani Bhardwaj almost 3 years ago
- Status changed from Assigned to In Progress
Updated by Shivani Bhardwaj almost 3 years ago
- Status changed from In Progress to In Review
Updated by Shivani Bhardwaj almost 3 years ago
- Status changed from In Review to Closed
Actions