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

Add execution information flags to tracee-ebpf #1041

Merged
merged 6 commits into from
Oct 7, 2021

Conversation

AsafEitani
Copy link
Contributor

Add process creation information to tracee-ebpf events.
The flag added is "-o option:exec-info" and calculates the file hash, file ctime and container ctime.
if the process was created on the host - it will get the mnt ctime.

Also changed the event for capturing to sched_process_exec instead of security_bprm_check.

There is a cache based on LRU for both container ctime and hash calculation.

@CLAassistant
Copy link

CLAassistant commented Oct 4, 2021

CLA assistant check
All committers have signed the CLA.

tracee-ebpf/tracee/events_processor.go Outdated Show resolved Hide resolved
tracee-ebpf/tracee/events_processor.go Outdated Show resolved Hide resolved
tracee-ebpf/tracee/events_processor.go Outdated Show resolved Hide resolved
tracee-ebpf/tracee/events_processor.go Outdated Show resolved Hide resolved
tracee-ebpf/tracee/events_processor.go Outdated Show resolved Hide resolved
tracee-ebpf/main.go Outdated Show resolved Hide resolved
@yanivagman
Copy link
Collaborator

LGTM!

@yanivagman yanivagman merged commit 4382fd8 into aquasecurity:main Oct 7, 2021
Copy link
Collaborator

@itaysk itaysk left a comment

Choose a reason for hiding this comment

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

I know too late for this PR, but capture-exec, capture-profile, and now output-execinfo have much in common, the code can be simplified.
also you forgot to document the flag.

@itaysk
Copy link
Collaborator

itaysk commented Oct 7, 2021

Not a feedback for this PR, but this demonstrated the problem we have with our "custom" events which are undocumented and unintuitive.
No one would expect hashes to appear on sched_process_exec. We added it there for arbitrary/technical convenience, eventually we need to find a better way and when we do it'll be a breaking change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants