[PR #28] [MERGED] Implement traffic accounting and limiting via an eBPF module #37

Closed
opened 2026-03-04 14:52:38 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/f00b4r0/uspot/pull/28
Author: @f00b4r0
Created: 6/19/2025
Status: Merged
Merged: 7/17/2025
Merged by: @f00b4r0

Base: nextHead: ebpf


📝 Commits (10+)

  • 0974fc8 Implement uspot-bpf, an eBPF traffic counter
  • e99809f introduce uspotbpf.uc
  • 7f6f438 uspotbpf: work around ucode-mod-bpf bug
  • 319e0c2 uspot: hook traffic accounting
  • ccf3fa9 uspot: client_interim(): remove dead code
  • 0e92cc9 uspotbpf: fix priority conflict with ratelimit
  • 55d40a8 uspot: implement traffic limiting
  • b05257e uspot: implement swapio
  • e83f950 uspot: radius_acct(): don't needlessly call uspotfilter
  • 442cff7 uspotfilter: cleanup unused API

📊 Changes

10 files changed (+387 additions, -63 deletions)

View changed files

📝 Makefile (+12 -2)
📝 README.md (+3 -2)
📝 files/etc/config/uspot (+2 -0)
📝 files/etc/radcli/dictionary.chillispot (+3 -0)
📝 files/usr/share/uspot/handler-api.uc (+25 -2)
📝 files/usr/share/uspot/portal.uc (+1 -0)
📝 files/usr/share/uspot/uspot.uc (+140 -40)
files/usr/share/uspot/uspotbpf.uc (+105 -0)
📝 files/usr/share/uspotfilter/uspotfilter.uc (+1 -17)
src/uspot-bpf.c (+95 -0)

📄 Description

Opening this PR for easy reference until the relevant changes are fully tested and merged

This PR addresses #9 and #25 implementing support for Acct-{Input,Output}-{Octets,Gigawords,Packets} attributes in RADIUS reporting and ChilliSpot-Max-{Input,Output,Total}-{Octets,Gigawords} for RADIUS-based traffic caps.

@PWJW @badnbusy @nemesifier feel free to chime in with your test results, thanks

Fixes: #9
Fixes: #25


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/f00b4r0/uspot/pull/28 **Author:** [@f00b4r0](https://github.com/f00b4r0) **Created:** 6/19/2025 **Status:** ✅ Merged **Merged:** 7/17/2025 **Merged by:** [@f00b4r0](https://github.com/f00b4r0) **Base:** `next` ← **Head:** `ebpf` --- ### 📝 Commits (10+) - [`0974fc8`](https://github.com/f00b4r0/uspot/commit/0974fc8d47accb12f36d3d08690c840d01567b25) Implement uspot-bpf, an eBPF traffic counter - [`e99809f`](https://github.com/f00b4r0/uspot/commit/e99809f97e3499477073444707ac9cc4f3bed70b) introduce uspotbpf.uc - [`7f6f438`](https://github.com/f00b4r0/uspot/commit/7f6f438835683e83c65656b2c0a6af1ff16f166b) uspotbpf: work around ucode-mod-bpf bug - [`319e0c2`](https://github.com/f00b4r0/uspot/commit/319e0c285afbe375f64d0ad6e2e231161893a8ee) uspot: hook traffic accounting - [`ccf3fa9`](https://github.com/f00b4r0/uspot/commit/ccf3fa9b8e830a56df24da8776fd2ed44a6fcf87) uspot: client_interim(): remove dead code - [`0e92cc9`](https://github.com/f00b4r0/uspot/commit/0e92cc9f6e75056be6c8491bdea3f7a6d4fc4e53) uspotbpf: fix priority conflict with ratelimit - [`55d40a8`](https://github.com/f00b4r0/uspot/commit/55d40a8794b698dd9941d1704f4baabc03cc6157) uspot: implement traffic limiting - [`b05257e`](https://github.com/f00b4r0/uspot/commit/b05257e862cb05dce3383c7fa11a301702c8de0e) uspot: implement swapio - [`e83f950`](https://github.com/f00b4r0/uspot/commit/e83f95081c218f20d80684be34ff1bc08d010103) uspot: radius_acct(): don't needlessly call uspotfilter - [`442cff7`](https://github.com/f00b4r0/uspot/commit/442cff77322050a56285138cdb8eb3b50231330b) uspotfilter: cleanup unused API ### 📊 Changes **10 files changed** (+387 additions, -63 deletions) <details> <summary>View changed files</summary> 📝 `Makefile` (+12 -2) 📝 `README.md` (+3 -2) 📝 `files/etc/config/uspot` (+2 -0) 📝 `files/etc/radcli/dictionary.chillispot` (+3 -0) 📝 `files/usr/share/uspot/handler-api.uc` (+25 -2) 📝 `files/usr/share/uspot/portal.uc` (+1 -0) 📝 `files/usr/share/uspot/uspot.uc` (+140 -40) ➕ `files/usr/share/uspot/uspotbpf.uc` (+105 -0) 📝 `files/usr/share/uspotfilter/uspotfilter.uc` (+1 -17) ➕ `src/uspot-bpf.c` (+95 -0) </details> ### 📄 Description Opening this PR for easy reference until the relevant changes are fully tested and merged This PR addresses #9 and #25 implementing support for `Acct-{Input,Output}-{Octets,Gigawords,Packets}` attributes in RADIUS reporting and `ChilliSpot-Max-{Input,Output,Total}-{Octets,Gigawords}` for RADIUS-based traffic caps. @PWJW @badnbusy @nemesifier feel free to chime in with your test results, thanks Fixes: #9 Fixes: #25 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-04 14:52:38 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/uspot#37
No description provided.