Project architecture
we have a loader library, a compile toolchain, and some additional tools like cli and a custom metrics exporter.
we have a loader library, a compile toolchain, and some additional tools like cli and a custom metrics exporter.

An bpf-loader-rs library
A wrapper of main functions of libbpf-rs, provide the ability to dynamically load eBPF code to the kernel and run it with a simple JSON and a few API.
see bpf-loader-rs for details.
A simple cli interface is provided for bpf-loader library, which you can use it to start any eBPF program from a url in a command. You can download it from release.
see examples for more examples.
A library to load and operate eBPF program from a WASM module
Use the eunomia-bpf library to load eBPF program from a WASM module, you can write a WASM module to operate the eBPF program or process the data in user space WASM runtime. The idea is simple:
- compile the kernel eBPF code skeleton to the
JSONformat witheunomia-cctoolchain - embed the
JSONdata in theWASMmodule, and provide some API for operating the eBPF program skeleton - load the
JSONdata from theWASMmodule and run the eBPF program skeleton witheunomia-bpflibrary
You can have multiple eBPF program in a single WASM module.
See wasm-runtime for details. In fact, wasm-bpf library only exports a few functions from bpf-loader library to the VM, so you can replace the WASM runtime with your own easily.
For example, you can run a locally built eBPF Wasm module with ecli:
sudo ./ecli run ./app.wasmYou can also generate a WASM program template for eBPF or build WASM module with compiler container:
# for x86_64 and aarch64
docker run -it -v `pwd`/:/src/ ghcr.io/eunomia-bpf/ecc-`uname -m`:latest gen-wasm-skel # generate WASM app template for eBPF
docker run -it -v `pwd`/:/src/ ghcr.io/eunomia-bpf/ecc-`uname -m`:latest build-wasm # Build WASM modulesee sigsnoop example for more detail.
A compile toolchain to help you generate pre compiled eBPF data
The toolchain can be used as a docker to generate pre-compiled eBPF data in one command:
see the compile toolchains compiler for details.
you can also use the eunomia-template repo as a GitHub template. Its publish workflow compiles src/package.json and publishes it as a GitHub release asset.
other related projects
-
LMP eBPF Hub: github.com/linuxkerneltravel/lmp
a package manager for eBPF based on wasm modules
-
bolipi online compiler & runner: https://bolipi.com/ebpf/home/online
an online compiler and runner for eBPF program newbies
-
An Observability tool
An prometheus and OpenTelemetry exporter for custom eBPF metrics, written in async rust: eunomia-exporter. You can compile it or download from release
Continue exploring
Back to index
eunomia-bpf Documentation
Simplify eBPF development with CO-RE and WebAssembly. Build, compile, and distribute eBPF programs easier with automatic code generation.
Previous
eunomia-bpf Documentation
Simplify eBPF development with CO-RE and WebAssembly. Build, compile, and distribute eBPF programs easier with automatic code generation.
Next
benchmark
Most of the time, bpf-loader work as a library to load eBPF program. It will not affect eBPF program after the program has been loaded and attached.
- Last updated
- Mar 8, 2026
- First published
- Aug 10, 2023
- Contributors
- 云微, oluceps
Was this page helpful?