Bug #3164
closed
Suricata 4.1.4: NSS Shutdown triggers crashes in test mode
Added by Yujie Zhao over 5 years ago.
Updated over 5 years ago.
Description
I'm trying to upgrade from Suricata 4.1.3 to 4.1.4. Both are built on the same Linux server. When I run Suricata 4.1.4, it always crashes at exit when NSS_Shutdown() is called. Seems NSS is not initialized successfully for 4.1.4.
Suricata 4.1.3 doesn't have this problem.
I'm running Suricata 4.1.4, and that's related to the problem.
It seems Suricata 4.1.4 won't initialize NSS in the testing mode, but 4.1.4 will.
Here is the root cause:
In 4.1.3, Suricata exits directly in the test mode:
if (suricata.run_mode RUNMODE_CONF_TEST){
SCLogNotice("Configuration provided was successfully loaded. Exiting.");
#ifdef HAVE_MAGIC
MagicDeinit();
#endif
exit(EXIT_SUCCESS);
}
In 4.1.4, the code is changed to support the engine analysis mode. Suricata doesn't exit directly, and instead it tries to clean up and that calls NSS_Shutdown() and triggers the crash.
if (suricata.run_mode RUNMODE_ENGINE_ANALYSIS) {
goto out;
} else if (suricata.run_mode == RUNMODE_CONF_TEST){
SCLogNotice("Configuration provided was successfully loaded. Exiting.");
goto out;
}
Yujie Zhao wrote:
I'm running Suricata 4.1.4, and that's related to the problem.
It seems Suricata 4.1.4 won't initialize NSS in the testing mode, but 4.1.3 will.
- Assignee set to Yujie Zhao
- Subject changed from Suricata 4.1.4: NSS not initialized to Suricata 4.1.4: NSS Shutdown triggers crashes in test mode
- Target version set to TBD
- Status changed from New to Closed
- Target version changed from TBD to 4.1.5
- Copied to Bug #3189: NSS Shutdown triggers crashes in test mode (5.x) added
Also available in: Atom
PDF