-
Notifications
You must be signed in to change notification settings - Fork 382
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
docs: update enforcement page #1630
Conversation
Override the return value of a call means that the function will never be executed and, instead, a | ||
value (typically an error) will be returned to the caller. Generally speaking, only system calls and | ||
security check functions allow to change their return value in this manner. Details about how users | ||
can configure tracing policies to override the return value can be found in the [Override | ||
action]({{< ref "/docs/concepts/tracing-policy/selectors#override-action" >}}) documentation. |
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.
Should we mention the kernel option? https://elixir.bootlin.com/linux/v5.13.18/source/kernel/trace/Kconfig#L601. Not really a review of this but maybe for another PR.
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.
Or we could have a Requirements section at some point would be another option.
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.
I think the option would be better suited in the Override action documentation (in the selectors) section.
performed by the process from being executed. For example, a `SIGKILL` might be send in a `write()` | ||
system call does not guarantee that the data will not be written to the file. |
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.
performed by the process from being executed. For example, a `SIGKILL` might be send in a `write()` | |
system call does not guarantee that the data will not be written to the file. | |
performed by the process from being executed. For example, a `SIGKILL` sent in a `write()` | |
system call does not guarantee that the data will not be written to the file. |
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.
Can we highlight what it does guarantee though. Maybe,
In contrast with overriding the return value, sending a
signal does not always stop the operation being performed
by the process that triggered the operation. However, it does
ensure that the process is terminated synchronously (and any
threads will be stopped). To ensure the operation is also
stopped the hook must be placed in the kernel carefully
to ensure the kernel performs a check for any signals before
the operation is performed.
In many cases it is sufficient to ensure the process is stopped
and unable to return from the call. Further, the kernel often
checks signals before doing I/O operations so these can be
used as long as kernel code paths are audited.
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.
Thanks! As discussed offline, I pushed the following:
In contrast with overriding the return value, sending a `SIGKILL` signal does not always stop the
operation being performed by the process that triggered the operation. For example, a `SIGKILL` sent
in a `write()` system call does not guarantee that the data will not be written to the file.
However, it does ensure that the process is terminated synchronously (and any threads will be
stopped). In some cases it may be sufficient to ensure the process is stopped and the process does
not handle the return of the call. To ensure the operation is not completed, though, the `Signal`
action should be combined with the `Override` action.
that's weird, the netlify preview was not triggered! the only time we need this it's not triggered 🤔 EDIT: we have it for the other PR that was closed #1629. This thing puzzles me |
2cf4476
to
ac240d8
Compare
✅ Deploy Preview for tetragon ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
ac240d8
to
3d20be9
Compare
Signed-off-by: Kornilios Kourtis <[email protected]>
3d20be9
to
424d22d
Compare
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.
I think we can merge this!
Merged. Let's improve later if need be. |
No description provided.