Skip to content
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

feature: remove policy actions #3314

Merged

Conversation

josedonizetti
Copy link
Collaborator

@josedonizetti josedonizetti commented Jul 12, 2023

1. Explain what the PR does

Fix #3313

This PR simplifies policies by removing defaultActions, and actions. The multiple actions feature creates a lot of complexity, which is not required.

This allows policy creation without the need to specify any action (default or per event). The default action is always output and will depend on the tracee output config to use file, webhook, fluentd, or multiple printers.

2. Explain how to test it

All the examples below should work:

name: dig
description: traces dns events from the dig binary
scope: 
  - binary=/usr/bin/dig
rules:
  - event: net_packet_dns_request        
  - event: net_packet_dns_response

or, for backward compatibility

name: dig
description: traces dns events from the dig binary
defaultActions:
  - log
scope: 
  - binary=/usr/bin/dig
rules:
  - event: net_packet_dns_request        
  - event: net_packet_dns_response

3. Other comments

This commit simplifies policies by removing defaultActions, and actions.
The multiple actions feature creates a lot of complexity, which is not
required.
Copy link
Collaborator

@yanivagman yanivagman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@josedonizetti josedonizetti marked this pull request as ready for review July 13, 2023 08:17
@josedonizetti josedonizetti merged commit d8fa964 into aquasecurity:main Jul 13, 2023
26 checks passed
@josedonizetti josedonizetti deleted the remove-policy-actions branch July 13, 2023 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

policies: remove defaultActions and actions
2 participants