Actions
Bug #7634
closedhyperscan: coverity warnings
Affected Versions:
Effort:
Difficulty:
Label:
Description
** CID 1645545: Memory - corruptions (USE_AFTER_FREE)
________________________________________________________________________________________________________
*** CID 1645545: Memory - corruptions (USE_AFTER_FREE)
/src/util-mpm-hs.c: 827 in SCHSPreparePatterns()
821
822 SCMutexUnlock(&g_db_table_mutex);
823 CompileDataFree(cd);
824 return 0;
825
826 error:
>>> CID 1645545: Memory - corruptions (USE_AFTER_FREE)
>>> Calling "SCHSCleanupOnError" frees pointer "cd" which has already been freed.
827 SCHSCleanupOnError(pd, cd);
828 return -1;
829 }
830
831 /**
832 * \brief Cache the initialized and compiled ruleset
** CID 1645544: Error handling issues (CHECKED_RETURN)
/src/detect-engine.c: 2578 in DetectEngineMpmCachingGetPath()
________________________________________________________________________________________________________
*** CID 1645544: Error handling issues (CHECKED_RETURN)
/src/detect-engine.c: 2578 in DetectEngineMpmCachingGetPath()
2572 if (DetectEngineMpmCachingEnabled() == false) {
2573 return NULL;
2574 }
2575
2576 char yamlpath[] = "detect.sgh-mpm-caching-path";
2577 const char *strval = NULL;
>>> CID 1645544: Error handling issues (CHECKED_RETURN)
>>> Calling "ConfGet" without checking return value (as is done elsewhere 94 out of 95 times).
2578 ConfGet(yamlpath, &strval);
2579
2580 if (strval != NULL) {
2581 return strval;
2582 }
2583
Updated by Victor Julien 7 months ago
Updated
** CID 1645571: Error handling issues (CHECKED_RETURN)
/src/detect-engine.c: 2599 in DetectEngineMpmCachingGetPath()
________________________________________________________________________________________________________
*** CID 1645571: Error handling issues (CHECKED_RETURN)
/src/detect-engine.c: 2599 in DetectEngineMpmCachingGetPath()
2593 if (DetectEngineMpmCachingEnabled() == false) {
2594 return NULL;
2595 }
2596
2597 char yamlpath[] = "detect.sgh-mpm-caching-path";
2598 const char *strval = NULL;
>>> CID 1645571: Error handling issues (CHECKED_RETURN)
>>> Calling "SCConfGet" without checking return value (as is done elsewhere 94 out of 95 times).
2599 SCConfGet(yamlpath, &strval);
2600
2601 if (strval != NULL) {
2602 return strval;
2603 }
2604
Updated by Lukas Sismis 5 months ago
- Status changed from Assigned to In Review
PR kicked off in https://github.com/OISF/suricata/pull/13276
Updated by Lukas Sismis 5 months ago
- Status changed from In Review to Closed
Actions