Commit Graph

43 Commits

Author SHA1 Message Date
Marco Cadetg
8622dd2d87 fix(ci): trigger AUR workflow on release publish instead of tag push
This avoids the race condition where the AUR workflow starts before
the release is created. Now it only runs after the release is published.
2025-12-07 13:24:42 +01:00
dependabot[bot]
1a47b1a8d8 chore(deps): bump vmactions/freebsd-vm in the actions group (#82)
Bumps the actions group with 1 update: [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm).


Updates `vmactions/freebsd-vm` from 1.2.7 to 1.2.8
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](b9c3f24600...0cd283ca69)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: actions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-04 21:00:57 +01:00
Marco Cadetg
3a8e8614bc feat: reorganize platform code into per-platform directories (#81)
* feat: reorganize platform code into per-platform directories

- Move platform files into linux/, macos/, windows/, freebsd/ subdirectories
- Unify create_process_lookup() API with _use_pktap parameter across all platforms
- Update build.rs paths for eBPF program location
- Reduce cfg attributes in main mod.rs from ~42 to 8

* fix: widen tolerance for test_sliding_window_no_skip_first_sample

Increase acceptable range from 9000-11000 to 5000-15000 to account
for timing variability on macOS ARM CI runners.

* docs: update Linux build dependencies and remove EBPF_BUILD.md

- Add missing build-essential, pkg-config, zlib1g-dev to documentation
- Update rust.yml CI with complete dependencies
- Remove EBPF_BUILD.md (info already in INSTALL.md)
- Update references in README.md and ARCHITECTURE.md
2025-11-30 18:08:11 +01:00
Marco Cadetg
fed1efaa30 Enhance Dependabot configuration for Rust and Actions
Added cooldown and grouping settings for Rust and GitHub Actions dependencies.
2025-11-26 08:10:24 +01:00
Marco Cadetg
abfac77826 Run Docker container as host user 2025-11-22 22:31:02 +01:00
Marco Cadetg
60f7f546ad Fix .SRCINFO file ownership 2025-11-22 22:26:21 +01:00
Marco Cadetg
d3053e1ec6 Run makepkg as non-root user 2025-11-22 22:24:41 +01:00
Marco Cadetg
f91731726b Fix tag detection for manual triggers 2025-11-22 22:23:25 +01:00
Marco Cadetg
51951a2dc0 Use latest tag for manual workflow triggers 2025-11-22 22:20:01 +01:00
Marco Cadetg
93902d3911 Fix AUR workflow version extraction 2025-11-22 22:18:45 +01:00
Marco Cadetg
2c0f0d7aae Add AUR package automation workflow 2025-11-22 22:12:05 +01:00
Marco Cadetg
f12a3e21cd chore: pin vmactions/freebsd-vm to v1.2.7 SHA 2025-11-22 18:59:05 +01:00
Marco Cadetg
b85d69114c Use FreeBSD VM for native builds instead of cross-compilation
- Removed freebsd-x64 from cross-compilation matrix
- Added dedicated build-freebsd job using vmactions/freebsd-vm
- Builds natively on actual FreeBSD using pkg and native toolchain
- Updated test-freebsd workflow to use VM as well
- Avoids all cross-compilation sysroot/libpcap issues
2025-11-22 18:17:48 +01:00
Marco Cadetg
99a7cbd033 Fix FreeBSD build by making libbpf-cargo optional
- Make libbpf-cargo an optional build dependency
- Include it in ebpf feature to only build when needed
- Add test workflow for FreeBSD builds that can be manually triggered
- This prevents libbpf-sys from being built when cross-compiling to FreeBSD
2025-11-22 17:58:36 +01:00
Marco Cadetg
9796af5b71 Fix FreeBSD build by disabling eBPF for non-Linux platforms 2025-11-22 17:50:20 +01:00
dependabot[bot]
eb4b72d318 chore(deps): bump actions/checkout from 5 to 6 (#78)
Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-21 17:34:02 +01:00
Marco Cadetg
85b2662c85 feat: add freebsd (#71)
* feat: add freebsd
2025-11-02 19:47:26 +01:00
dependabot[bot]
434a2edb5b chore(deps): bump actions/upload-artifact from 4 to 5 (#67)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-27 13:02:42 +01:00
dependabot[bot]
0ac881c75c chore(deps): bump actions/download-artifact from 5 to 6 (#66)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-27 13:02:23 +01:00
dependabot[bot]
cde043b9d4 chore(deps): bump actions/download-artifact from 4 to 5 (#49)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 15:38:42 +02:00
dependabot[bot]
02b09fd800 chore(deps): bump docker/build-push-action from 5 to 6 (#50)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 5 to 6.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](https://github.com/docker/build-push-action/compare/v5...v6)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 15:38:14 +02:00
dependabot[bot]
4c79b5ce8f chore(deps): bump actions/checkout from 4 to 5 (#51)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 15:38:01 +02:00
dependabot[bot]
74d9dc4302 chore(deps): bump actions/attest-build-provenance from 1 to 3 (#52)
Bumps [actions/attest-build-provenance](https://github.com/actions/attest-build-provenance) from 1 to 3.
- [Release notes](https://github.com/actions/attest-build-provenance/releases)
- [Changelog](https://github.com/actions/attest-build-provenance/blob/main/RELEASE.md)
- [Commits](https://github.com/actions/attest-build-provenance/compare/v1...v3)

---
updated-dependencies:
- dependency-name: actions/attest-build-provenance
  dependency-version: '3'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 15:37:43 +02:00
Marco Cadetg
38223c3265 chore: add dependabot configuration 2025-10-14 15:31:11 +02:00
Marco Cadetg
a402cdd545 docs: add Ubuntu PPA and Fedora COPR installation instructions (#48)
- Add Ubuntu PPA section to INSTALL.md (requires Ubuntu 25.10+)
- Add Fedora COPR section to INSTALL.md (requires Fedora 42+)
- Update README.md Quick Start with PPA/COPR as recommended methods
- Add GitHub Actions workflow to auto-update RPM spec version on tag push
2025-10-14 10:33:42 +02:00
Marco Cadetg
3c4d5e4bc1 Add Ubuntu PPA packaging support (#47)
Adds Ubuntu PPA packaging with automated GitHub Actions workflow.

- Debian packaging files in debian/ directory
- GitHub Actions workflow for automated PPA uploads
- Targets Ubuntu Questing (25.10) with Rust 1.88
2025-10-14 09:24:53 +02:00
Marco Cadetg
a2b2e09b0b fix: shell variable expansion in changelog generation 2025-10-13 12:00:37 +02:00
Marco Cadetg
ddcc51ffbf fix: YAML syntax error in PPA workflow 2025-10-13 11:58:14 +02:00
Marco Cadetg
e0de0c42a7 feat: add GitHub Actions workflow for Ubuntu PPA releases
- Add automated PPA build workflow for Ubuntu 22.04 and 24.04
- Build and sign packages using CI GPG key
- Auto-upload to ppa:domcyrus/rustnet on git tags
- Add complete Debian packaging files
2025-10-13 11:51:27 +02:00
Marco Cadetg
52fb1c2cce feat: make eBPF default on Linux (#46)
Make eBPF the default build configuration on Linux for better
performance and lower overhead process identification.

Changes:
- Set default features to include ebpf in Cargo.toml
- Remove explicit --features linux-default from build configs
- Update all documentation to reflect eBPF is now default
- Add instructions for building without eBPF (--no-default-features)

eBPF automatically falls back to procfs if it fails to load.

Closes #32
2025-10-12 13:53:11 +02:00
Marco Cadetg
9f5ef592bf chore: use ubuntu 22.04 on linux x86 builds 2025-10-09 15:03:49 +02:00
Marco Cadetg
12a7d2e51a fix: add build dependencies to publish workflow 2025-10-02 09:07:41 +02:00
Marco Cadetg
e22c95fec1 fix: remove vmlinux crate dep (#28)
* fix: remove vmlinux crate dep

* fix: download architecture-specific vmlinux.h at build time

Instead of using a git dependency (not allowed on crates.io), download the
architecture-specific vmlinux.h header at build time from the libbpf/vmlinux.h
repository. This approach:

- Removes git dependency from Cargo.toml (crates.io compatible)
- Downloads correct arch-specific header (x86, aarch64, arm)
- Caches downloaded headers in OUT_DIR (reuses between builds)
- Works with cargo install
- Supports cross-compilation for all architectures

The vmlinux.h file (~3-4MB per arch) is downloaded once per architecture
and cached, so subsequent builds are fast.

* fix: use ureq with rustls instead of http_req

http_req depends on native-tls/openssl-sys which requires OpenSSL to be
installed in the cross-compilation containers. Switch to ureq with the
rustls backend which has no system dependencies and works in all
cross-compilation environments.

* fix: follow symlink when downloading vmlinux.h

The vmlinux.h files in the libbpf/vmlinux.h repository are symlinks to
versioned files (e.g. vmlinux_6.14.h). When downloading via
raw.githubusercontent.com, we get the symlink content (just the target
filename) instead of the actual file.

Solution: Download the symlink first to get the target filename, then
download the actual versioned file. This ensures we get the full header
content instead of just the symlink text.

* add crate publish workflow
2025-10-02 08:49:20 +02:00
Marco Cadetg
dceb949652 fix: remove armv7 again for docker 2025-09-30 10:17:45 +02:00
Marco Cadetg
99c69e6f51 feat: ebpf docker builds 2025-09-30 09:59:22 +02:00
Marco Cadetg
42db7f5614 fix: release workflow (#17)
* Remove musl targets to simplify Linux builds and fix cross-compilation issues
* Enable eBPF by default on Linux via linux-default feature for better packet capture
* Add macOS code signing and notarization support with graceful fallback for unsigned builds
* Fix Windows MSI packaging with improved WiX configuration and Npcap library linking
* Auto-extract changelog content from CHANGELOG.md into GitHub release notes
* Fix ARM cross-compilation (aarch64, armv7) with proper library paths and eBPF support
* Add comprehensive installation documentation for DMG, MSI, DEB, and RPM packages
* Allow re-running releases with --clobber flag for artifact uploads
2025-09-30 09:39:26 +02:00
Marco Cadetg
d9798f9605 maybe fix windows msi packaging 2025-09-29 21:57:44 +02:00
Marco Cadetg
eca0e6000d feat: add cross-platform packaging and release automation
- Add GitHub Actions workflow for automated releases
- Create .deb, .rpm, AppImage, .dmg, and .msi packages
- Generate shell completions and manpages in build.rs
- Add platform-specific icons from rustnet3.svg
- Include eBPF dependencies for Linux packages
- Support Windows 32-bit and 64-bit builds
- Extract shared CLI module to prevent duplication
2025-09-29 11:56:55 +02:00
Marco Cadetg
799d66cf86 feat: Add experimental eBPF support for enhanced socket tracking (#11)
* feat: Add experimental eBPF support for enhanced socket tracking

- Implement eBPF-based socket tracker for Linux with CO-RE support
- Add minimal vmlinux header (5.5KB) instead of full 3.4MB file
- Create graceful fallback mechanism to procfs when eBPF unavailable
- Add comprehensive eBPF build documentation
- Integrate libbpf-rs for eBPF program loading and management
- Support both IPv4 and IPv6 socket tracking
- Add capability checking for required permissions

The eBPF feature is optional and disabled by default. When enabled,
it provides faster and more accurate process-to-socket mapping on
Linux systems with appropriate permissions.
2025-09-18 11:46:03 +02:00
Marco Cadetg
4ecda96d68 ci: improve gh actions with path-based triggers 2025-09-11 11:47:49 +02:00
Marco Cadetg
d07ec2ae77 add docker container 2025-09-10 14:33:03 +02:00
Marco Cadetg
45056d41c8 Install libpcap-dev in CI workflow
Added step to install libpcap-dev before building the project.
2025-09-09 17:14:50 +02:00
Marco Cadetg
8a8d11ff8b Add GitHub Actions workflow for Rust project 2025-09-09 17:10:45 +02:00