TMA project
Build:
DOCKER_BUILDKIT=1 docker-compose build
Up:
docker-compose up -d
Server available on http://localhost:8000
First, follow instruction from eBPF_code/README.md to generate the corresponding eBPF code and eBPF maps.
Then, you can build the middleware with:
$: go build .
Or just run it with:
$: go run main.go
The server will be available on port http://localhost:8000.
Note: make sure to run the middleware as root.
GET /flows
Response:
# id,src_ip,src_port,dst_ip,dst_port,protocol,blocked,speed(Bps),bytes
ac120001ac120002d0001f4006000000,172.18.0.1,53248,172.18.0.2,8000,6,0,0.000000,2328415923817
POST /flows/{id}/block
POST /flows/{id}/unblock