• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..19-Jul-2021-

asm/H19-Jul-2021-1,8151,303

internal/H19-Jul-2021-3,8532,790

link/H19-Jul-2021-850607

.clang-formatH A D19-Jul-2021491 1817

.gitignoreH A D19-Jul-2021196 1411

ARCHITECTURE.mdH A D19-Jul-20213.5 KiB8162

CODE_OF_CONDUCT.mdH A D19-Jul-20213.2 KiB4728

CONTRIBUTING.mdH A D19-Jul-20211,014 2317

LICENSEH A D19-Jul-20211.1 KiB2419

MakefileH A D19-Jul-20212 KiB6843

README.mdH A D19-Jul-20211.9 KiB5539

collection.goH A D19-Jul-202114.1 KiB590399

doc.goH A D19-Jul-2021837 171

elf_reader.goH A D19-Jul-202125.6 KiB931702

elf_reader_fuzz.goH A D19-Jul-2021347 2215

go.modH A D19-Jul-2021177 107

go.sumH A D19-Jul-20211.1 KiB1413

info.goH A D19-Jul-20215.1 KiB240173

linker.goH A D19-Jul-20212.9 KiB13494

map.goH A D19-Jul-202129.7 KiB1,189811

marshalers.goH A D19-Jul-20215.6 KiB217161

pinning.goH A D19-Jul-2021880 4336

prog.goH A D19-Jul-202118.3 KiB699457

run-tests.shH A D19-Jul-20212.3 KiB9269

syscalls.goH A D19-Jul-202111.9 KiB492420

types.goH A D19-Jul-20216.5 KiB214125

types_string.goH A D19-Jul-20216.1 KiB169144

README.md

1# eBPF
2
3[![PkgGoDev](https://pkg.go.dev/badge/github.com/cilium/ebpf)](https://pkg.go.dev/github.com/cilium/ebpf)
4
5eBPF is a pure Go library that provides utilities for loading, compiling, and
6debugging eBPF programs. It has minimal external dependencies and is intended to
7be used in long running processes.
8
9* [asm](https://pkg.go.dev/github.com/cilium/ebpf/asm) contains a basic
10  assembler
11* [link](https://pkg.go.dev/github.com/cilium/ebpf/link) allows attaching eBPF
12  to various hooks
13* [perf](https://pkg.go.dev/github.com/cilium/ebpf/perf) allows reading from a
14  `PERF_EVENT_ARRAY`
15* [cmd/bpf2go](https://pkg.go.dev/github.com/cilium/ebpf/cmd/bpf2go) allows
16  embedding eBPF in Go
17
18The library is maintained by [Cloudflare](https://www.cloudflare.com) and
19[Cilium](https://www.cilium.io). Feel free to
20[join](https://cilium.herokuapp.com/) the
21[#libbpf-go](https://cilium.slack.com/messages/libbpf-go) channel on Slack.
22
23## Current status
24
25The package is production ready, but **the API is explicitly unstable right
26now**. Expect to update your code if you want to follow along.
27
28## Requirements
29
30* A version of Go that is [supported by
31  upstream](https://golang.org/doc/devel/release.html#policy)
32* Linux 4.9, 4.19 or 5.4 (versions in-between should work, but are not tested)
33
34## Useful resources
35
36* [eBPF.io](https://ebpf.io) (recommended)
37* [Cilium eBPF documentation](https://docs.cilium.io/en/latest/bpf/#bpf-guide)
38  (recommended)
39* [Linux documentation on
40  BPF](https://www.kernel.org/doc/html/latest/networking/filter.html)
41* [eBPF features by Linux
42  version](https://github.com/iovisor/bcc/blob/master/docs/kernel-versions.md)
43
44## Regenerating Testdata
45
46Run `make` in the root of this repository to rebuild testdata in all
47subpackages. This requires Docker, as it relies on a standardized build
48environment to keep the build output stable.
49
50The toolchain image build files are kept in [testdata/docker/](testdata/docker/).
51
52## License
53
54MIT
55