-
Notifications
You must be signed in to change notification settings - Fork 910
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(engine): disable comma separated vectors in cxxopts #3363
fix(engine): disable comma separated vectors in cxxopts #3363
Conversation
Signed-off-by: Luca Guerra <[email protected]>
/milestone 0.40.0 buf if there is a 0.39.1 this would get in. |
👍 /milestone 0.39.1 |
@@ -19,6 +19,9 @@ limitations under the License. | |||
#include "../configuration.h" | |||
#include "config_falco.h" | |||
|
|||
// disable cxxopts vector delimiter, meaning that | |||
// -o test1,test2,test3 won't be treated like -o test1 -o test2 -o test3 | |||
#define CXXOPTS_VECTOR_DELIMITER '\0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This may be seen as a (minor) breaking change in the CLI context. Is there an alternative available?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does not look like it as it happens unconditionally for vector<T>
values: https://github.com/jarro2783/cxxopts/blob/63d1b65a694cfceafc20863afa75df49dfbe6b2a/include/cxxopts.hpp#L1100
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: FedeDP, LucaGuerra The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
LGTM label has been added. Git tree hash: f25600afeb2dd2b07de6e3320b95fd3025df5179
|
What type of PR is this?
/kind bug
Any specific area of the project related to this PR?
/area engine
What this PR does / why we need it:
There was a missed configuration option in this PR #3310 , which sadly made the
-o append_output[]={"source": "syscall", "tag": "persistence", "rule": "some rule name", "format": "gparent=%proc.aname[2] ggparent=%proc.aname[3] gggparent=%proc.aname[4]"}
style options non functional due to the fact that cxxopts is trying to parse commas in the json object. Sadly I only realized after release. This PR fixes it.Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?: