ebpf
ebpf copied to clipboard
ebpf-go is a pure-Go library to read, modify and load eBPF programs and attach them to various hooks in the Linux kernel.
golangci-lint is not better than staticcheck for our purposes, in fact it includes a copy of the latter's ruleset. It also just broke the build by somehow breaking a tagged...
Add rewrite_constants example. The function of this sample program is to monitor the number of calls to the target system call made by the process every second. The target system...
### Is there an existing issue for this? - [X] I have searched the existing issues ### Version higher than v1.14.13 and lower than v1.15.0 ### What happened? use bpf2go,...
Hello! 👋 I'm implementing a Telegraf plugin that extracts metadata information from the `bpf_prog_info` object. There's some additional fields that I'd like to include in the metric, that aren't exposed...
Extract imports from "bpf2go.hfiles.go" in the output dir, scan packages for header files, and expose headers to clang. C code consumes headers by providing a go package path in include...
`cilium/ebpf` can detect if a symbol is part of a kmod and load it automatically. This is done [here](https://github.com/cilium/ebpf/blob/5976561b28aabf23df00f3507cc3b240305b531b/prog.go#L158-L177) by checking the function name that the user wants to attach...
When using btfgen (to provide BTF information for kernels without BTF support), spec.LoadAndAssign() is called with opts.KernelTypes but without opts.KernelModuleTypes. In this scenario, newProgramWithOptions() never makes use of kmod. Therefore...
Fixes https://github.com/cilium/ebpf/issues/1566. Before this patch, ebpf.LoadPinnedMap and ebpf.LoadPinnedProg both succeed when used with the wrong object type. Meaning that you can open a prog using epbf.LoadPinnedMap or vice-versa and you'll...
See individual commits for more detailed information. - [ ] Extend Global Variables documentation