-
Notifications
You must be signed in to change notification settings - Fork 6
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
Action semantics and related improvements #277
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #277 +/- ##
==========================================
+ Coverage 83.09% 83.21% +0.11%
==========================================
Files 115 119 +4
Lines 4566 4735 +169
Branches 2143 2253 +110
==========================================
+ Hits 3794 3940 +146
- Misses 300 304 +4
- Partials 472 491 +19
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
BenchmarksBenchmark execution time: 2024-03-27 16:15:54 Comparing candidate commit d5a33d8 in PR branch Found 3 performance improvements and 1 performance regressions! Performance is the same for 15 metrics, 0 unstable metrics. scenario:regex_match_matcher.case_insensitive_flag.random
scenario:regex_match_matcher.case_insensitive_option.random
scenario:regex_match_matcher.lowercase_transformer.random
scenario:regex_match_matcher.random
|
ddwaf_object tmp; | ||
ddwaf_object tags_map; | ||
|
||
ddwaf_object_map(&rule_map); |
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.
a bit of an aside, but I think it would be better at some point having a better (i.e, more efficient and expressive) for building ddwaf objects. Maybe something like this: https://github.com/DataDog/dd-trace-cpp/blob/60eed64ebbf89e85276d31f99f222d880ef88ae4/src/datadog/remote_config.cpp#L133-L152
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.
Indeed, this is sorely needed, thanks for the tip.
* Replace action_mapper setters with action_mapper_builder * Simplify UUID generation * Refactor serialisation
block
,redirect
) and other actions.ddwaf_result
in map format, ensuring that only one blocking action (redirect > block
) is provided. When two equivalent blocking actions are found, the first one takes precedence.stack_trace
action and generate pseudo-uuidv4 during result serialisation.monitor
andextract_schema
actions.