-
Notifications
You must be signed in to change notification settings - Fork 1
ROX-30258: Track file ownership changes #156
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
Conversation
e94e169 to
f0c48bd
Compare
39cf241 to
f15de82
Compare
f1e642b to
aa0399a
Compare
003e113 to
bbabdca
Compare
3a8ef28 to
b948cef
Compare
b96120b to
1746a5f
Compare
223faed to
9af8d73
Compare
aeee08e to
ff2f6db
Compare
missing user/group mapping to string representation
a362c36 to
57a6cb3
Compare
57a6cb3 to
16cc780
Compare
Molter73
left a comment
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.
Just a few comments but nothing major really. Feel free to ignore the ones marked with [nit].
| } | ||
|
|
||
| SEC("lsm/path_chown") | ||
| int BPF_PROG(trace_path_chown, struct path* path, unsigned long long uid, unsigned long long gid) { |
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.
[nit] It'd be nice to have a small comment here explaining why uid and gid are unsigned long long instead of kuid_t and kgid_t, in case someone comes in without the context in the future and attempts to change it.
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 added a comment in b381565 . I hope it makes sense.
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's fine, maybe we can mention the verifier does not allow struct types as arguments, so we do this instead.
Co-authored-by: Mauro Ezequiel Moltrasio <mmoltras@redhat.com>
... to submit_ownership_event()
Co-authored-by: Mauro Ezequiel Moltrasio <mmoltras@redhat.com>
Co-authored-by: Mauro Ezequiel Moltrasio <mmoltras@redhat.com>
Co-authored-by: Mauro Ezequiel Moltrasio <mmoltras@redhat.com>
Molter73
left a comment
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.
LGTM!
Description
Listen for chown LSM events.
Known limitations:
Checklist
Automated testing