Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature(events): turn SchedProcessXXX control plane enabled
- ADD parent_start_time argument to event context (*) - move functions containing inline asm to the end of their files - create buffer_memcpy() for map-to-map buffer copy in ebpf - sched_process_fork: - create a signal handler for a SchedProcessFork signal event - only SUBMIT the SchedProcessFork event if picked by a policy - ALWAYS submit the SchedProcessFork signal event (args only) - sched_process_exec: - create a signal handler for a SchedProcessExec signal event - only SUBMIT the SchedProcessExec event if picked by a policy - ALWAYS submit the SchedProcessFork signal event (args only) - sched_process_exit: - create a signal handler for a SchedProcessExit signal event - only SUBMIT the SchedProcessExit event if picked by a policy - ALWAYS submit the SchedProcessExit signal event (args only) - The SchedProcessExit signal event has extra 2 arguments added, both will be needed for the process tree implementation. - create a list of essential events coming from the control plane package, instead of a function within Tracee type. - add a 'Control' boolean to EventState to control whether the event, and its dependant events, should only be configured because of the control plane. This is needed because some events are too complex to have duplicated probes (they involve having tailCalls and other dependencies), so the same event probes are used to submit the regular AND the signal events. (*) parent_start_time argument to event context: The reason to have parent start time argument added is to have an unique identifier, using 'host_tid' + 'process start time' (using the murmur3 hashing function), on each submitted event. This way, the process tree is able to identify process parent using the process hash (and each ever existing process node entry in the process tree is hashed and unique). => The reasoning will be cleared in next commits. NOTE: There are NO logical changes to eBPF code but to copy the scratch buffer and submit it into the signal events perfbuffer.
- Loading branch information