mirror of
https://github.com/falcosecurity/falco.git
synced 2025-09-15 06:19:12 +00:00
Add a load result interface for use in new load_rules methods
Define a falco_load_result abstract class for use in new load_rules methods. It's abstract so the implementation details in rule_loader/rule_reader can be hidden from someone who wants to use the API to load rules and work with a result. The class defines a set of error codes/warning codes and has static methods to get a short and long description of each error/warning. There are virtual methods to access the important parts of a result: - successful or not - a string representation of the result, suitable for display to users. Takes a verbose argument. When verbose is true, the string is multi-line and has full details, including locations, item names, etc. When verbose is false, the string is single-line and just returns error codes. - a json representation of the result, suitable for automated parsing/interpretation later. Signed-off-by: Mark Stemm <mark.stemm@gmail.com>
This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
set(FALCO_ENGINE_SOURCE_FILES
|
||||
falco_common.cpp
|
||||
falco_engine.cpp
|
||||
falco_load_result.cpp
|
||||
falco_utils.cpp
|
||||
json_evt.cpp
|
||||
evttype_index_ruleset.cpp
|
||||
|
Reference in New Issue
Block a user