Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add LSM dynamic parameter extraction in
genericlsm.go
This commit update `addLsm` function to use the parameters `ExtractParam` and `OverwriteType` in order to look for the child members in BTF structure. It does a basic split on `ExtractParam` and to obtain the path from the argument to the required data. Then, the array is gave to `btf.FindNextBTFType` to find the offsets to the data. The output is stored in EventConfig to keep the normal behaviour For example, if the arg 0 is `struct linux_binprm` and ExtractParam is set to `file.f_path.dentry.d_name.name`, the output will give an array of all the offsets from there parents as such [{ offset: 96, is_pointer: 0 }, { offset: 152, is_pointer: 1 }, ...] Signed-off-by: Tristan d'Audibert <[email protected]>
- Loading branch information