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 support to load LSM and Tracing programs #953

Merged
merged 2 commits into from May 4, 2023
Merged

Conversation

tpapagian
Copy link
Member

@tpapagian tpapagian commented Apr 27, 2023

Also update cilium/ebpf to v0.10.0.

@tpapagian tpapagian changed the title Test Add support to load LSM and Tracing programs Apr 28, 2023
Signed-off-by: Anastasios Papagiannis <tasos.papagiannnis@gmail.com>
Signed-off-by: Anastasios Papagiannis <tasos.papagiannnis@gmail.com>
@tpapagian tpapagian marked this pull request as ready for review May 3, 2023 09:54
@tpapagian tpapagian requested a review from a team as a code owner May 3, 2023 09:54
@tpapagian tpapagian requested review from tixxdz and kkourt May 3, 2023 09:54
Copy link
Contributor

@kkourt kkourt left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

func TracingAttach(load *Program) AttachFunc {
return func(prog *ebpf.Program, spec *ebpf.ProgramSpec) (unloader.Unloader, error) {
linkFn := func() (link.Link, error) {
return link.AttachTracing(link.TracingOptions{
Copy link
Contributor

Choose a reason for hiding this comment

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

is this for fentry?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, this can be used for fentry, fexit, and fmod_ret programs.

@kkourt kkourt merged commit 9e19339 into main May 4, 2023
18 checks passed
@kkourt kkourt deleted the pr/apapag/update_ebpf branch May 4, 2023 06:33
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

2 participants