Commit Graph

327 Commits

Author SHA1 Message Date
Marco Cadetg
c498380c15 fix: use as_ref() for safer pointer dereference in interface stats 2025-12-21 14:36:43 +01:00
Marco Cadetg
844f82ce60 Add reverse DNS hostnames to Details tab and filter PTR traffic (#104)
* feat: add reverse DNS resolution for IP addresses

- Add --resolve-dns flag to enable background DNS resolution
- Add --show-ptr-lookups flag to show/hide PTR lookup connections
- Create dns.rs module with async resolver and LRU cache
- Display hostnames in UI with 'd' key toggle
- Include hostname fields in JSON log output when resolved

Closes #97
2025-12-21 14:29:12 +01:00
Marco Cadetg
37486111c4 feat(logging): add pid, process_name, service_name to JSON log (#102)
* feat(logging): add pid, process_name, service_name to JSON log (#99)

* feat(logging): add connection direction to JSON log for TCP
2025-12-20 17:48:49 +01:00
Marco Cadetg
4108b68625 feat(cli): show platform-specific options in help (#101) 2025-12-19 08:04:25 +01:00
Marco Cadetg
9089403d32 fix(macos): skip PKTAP when BPF filter is specified (#100)
BPF filters are incompatible with PKTAP (linktype 149) on macOS.
When a filter is specified, fall back to regular interface capture.
2025-12-19 07:53:16 +01:00
dependabot[bot]
925d721670 chore(deps): bump the actions group across 1 directory with 3 updates (#94)
Bumps the actions group with 3 updates in the / directory: [actions/upload-artifact](https://github.com/actions/upload-artifact), [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) and [actions/download-artifact](https://github.com/actions/download-artifact).


Updates `actions/upload-artifact` from 5 to 6
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6)

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

Updates `actions/download-artifact` from 6 to 7
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: actions
- dependency-name: actions/download-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
  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-15 12:57:37 +01:00
Marco Cadetg
9f81385861 feat(ui): add network health visualization to Graph tab (#93)
* feat(ui): add network health visualization to Graph tab

- Add RTT/latency tracking via TCP SYN-ACK timing
- Add packet loss percentage tracking from retransmit counts
- Add Network Health chart with dual-axis (RTT + loss)
- Add TCP States panel showing connection state distribution
- Add per-connection RTT display in Details tab
2025-12-14 17:59:54 +01:00
Marco Cadetg
2a1d58762b feat(cli): add --bpf-filter option for packet capture filtering (#92)
* Update demo GIF

* feat(cli): add --bpf-filter option for packet capture filtering
2025-12-13 15:21:59 +01:00
Marco Cadetg
c6c0c57028 fix(linux): handle clipboard access blocked by Landlock sandbox (#91)
Show helpful message when clipboard fails due to sandbox restrictions,
informing users to use --no-sandbox flag. Also adds wl-copy fallback
for Wayland environments where arboard fails.
2025-12-13 10:06:50 +01:00
Marco Cadetg
4c02a302d8 feat(ui): add traffic visualization and Graph tab (#90)
- Add traffic history tracking with 60-second ring buffer
- Add Graph tab with traffic and connection charts
- Add sparklines to Interface Stats on Overview
- Add Tab/Shift+Tab navigation between tabs
2025-12-13 10:06:32 +01:00
dependabot[bot]
9ae9921d14 chore(deps): bump the rust-dependencies group with 2 updates (#89)
Bumps the rust-dependencies group with 2 updates: [log](https://github.com/rust-lang/log) and [libc](https://github.com/rust-lang/libc).


Updates `log` from 0.4.28 to 0.4.29
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.28...0.4.29)

Updates `libc` from 0.2.177 to 0.2.178
- [Release notes](https://github.com/rust-lang/libc/releases)
- [Changelog](https://github.com/rust-lang/libc/blob/0.2.178/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/libc/compare/0.2.177...0.2.178)

---
updated-dependencies:
- dependency-name: log
  dependency-version: 0.4.29
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-dependencies
- dependency-name: libc
  dependency-version: 0.2.178
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-08 20:49:25 +01:00
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
Marco Cadetg
8ecdc94108 Release v0.17.0
- Add Landlock sandbox and capability dropping for Linux security
- Reorganize platform code into per-platform directories
- Add eBPF thread name resolution to main process names
- Add AUR package automation workflow
- Simplify QUIC DPI and unify SNI extraction
- Fix RateTracker test determinism
v0.17.0
2025-12-07 11:49:53 +01:00
Marco Cadetg
b12b7d38ab fix(linux): resolve eBPF thread names to main process names (#87)
Use periodic procfs PID cache to resolve thread names (e.g. 'Socket Thread')
to main process names (e.g. 'firefox'). Falls back to eBPF name for
short-lived processes that have already exited.
2025-12-07 11:24:58 +01:00
Marco Cadetg
c31909bff8 update rustnet gif 2025-12-06 18:04:41 +01:00
Marco Cadetg
5a059a3a12 feat: add Landlock sandbox and capability dropping for Linux (#86)
* feat: add Landlock sandbox and capability dropping for Linux

- Restrict filesystem access to /proc only after initialization
- Block TCP bind/connect on kernel 6.4+ (network sandbox)
- Drop CAP_NET_RAW after pcap handle opened
- Add --no-sandbox and --sandbox-strict CLI options
- Show privilege info on non-Linux platforms in UI
- Add SECURITY.md documentation

* fix: remove unused set_sandbox_info and hide Landlock line on non-Linux

* fix: gate SandboxInfo to Linux only to fix clippy warnings

* fix: add is_admin() function for Windows builds

The Windows build was failing because ui.rs called crate::is_admin()
but the function didn't exist. Added the implementation using Windows
Security API to check if the process has elevated privileges.

Also added Win32_Security feature to windows crate dependencies.

* fix: add is_admin() to main.rs for Windows binary crate

The previous fix added is_admin() to lib.rs but ui.rs is compiled
as part of the binary crate (main.rs), not the library crate.
Added the function to main.rs so crate::is_admin() resolves correctly.
2025-12-06 17:50:21 +01:00
Marco Cadetg
dd0b7e0923 fix: make RateTracker tests deterministic with injectable timestamps (#85) 2025-12-06 15:36:05 +01:00
Marco Cadetg
5c8ca435b3 refactor: simplify QUIC DPI and reorganize platform code (#84)
* refactor: simplify QUIC DPI and unify SNI extraction helpers

* refactor: reorganize platform code and improve code structure
2025-12-06 13:31:17 +01:00
dependabot[bot]
2fb66fe478 chore(deps): bump pcap in the rust-dependencies group (#83)
Bumps the rust-dependencies group with 1 update: [pcap](https://github.com/rust-pcap/pcap).


Updates `pcap` from 2.3.0 to 2.4.0
- [Changelog](https://github.com/rust-pcap/pcap/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rust-pcap/pcap/compare/v2.3.0...v2.4.0)

---
updated-dependencies:
- dependency-name: pcap
  dependency-version: 2.4.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: rust-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-04 21:02:41 +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
8db02be5fe Release v0.16.1
- Fix cross-compilation build issues for eBPF on non-Linux platforms
- Switch FreeBSD to native VM builds instead of cross-compilation
- Fix build.rs to check TARGET instead of host platform
v0.16.1
2025-11-22 18:35:49 +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
v0.16.0
2025-11-22 18:17:48 +01:00
Marco Cadetg
972d4de2f4 Fix FreeBSD build: make libbpf-cargo optional and add libpcap to Cross.toml
- Made libbpf-cargo an optional build dependency
- Only builds when ebpf feature is enabled
- Added Cross.toml configuration for FreeBSD to install libpcap
- Verified libbpf-sys no longer tries to build for FreeBSD
- Now fixing linker error for missing libpcap
2025-11-22 18:07:36 +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
68ab2a1b57 Fix build.rs to check TARGET instead of host for eBPF compilation 2025-11-22 17:53:41 +01:00
Marco Cadetg
9796af5b71 Fix FreeBSD build by disabling eBPF for non-Linux platforms 2025-11-22 17:50:20 +01:00
Marco Cadetg
3fc3a7d017 Release v0.16.0
- Network interface statistics feature with cross-platform support
- Link layer parsing improvements and modularization
- Windows and macOS interface statistics fixes
2025-11-22 17:41:14 +01:00
Marco Cadetg
6e1426170b Feature/interface stats (#79)
* feat: adding interface stats

* macOS specific improvements

* fix windows interface stats
2025-11-22 17:34:53 +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
dependabot[bot]
6f00d83f4c chore(deps): bump clap from 4.5.52 to 4.5.53 (#76)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.52 to 4.5.53.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.52...clap_complete-v4.5.53)

---
updated-dependencies:
- dependency-name: clap
  dependency-version: 4.5.53
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-20 16:40:37 +01:00
dependabot[bot]
e15a567924 chore(deps): bump clap_complete from 4.5.60 to 4.5.61 (#77)
Bumps [clap_complete](https://github.com/clap-rs/clap) from 4.5.60 to 4.5.61.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.60...clap_complete-v4.5.61)

---
updated-dependencies:
- dependency-name: clap_complete
  dependency-version: 4.5.61
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-20 16:40:21 +01:00
dependabot[bot]
cbef7e4457 chore(deps): bump bytes from 1.10.1 to 1.11.0 (#73)
Bumps [bytes](https://github.com/tokio-rs/bytes) from 1.10.1 to 1.11.0.
- [Release notes](https://github.com/tokio-rs/bytes/releases)
- [Changelog](https://github.com/tokio-rs/bytes/blob/master/CHANGELOG.md)
- [Commits](https://github.com/tokio-rs/bytes/compare/v1.10.1...v1.11.0)

---
updated-dependencies:
- dependency-name: bytes
  dependency-version: 1.11.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-18 18:22:21 +01:00
dependabot[bot]
183ec7f2b2 chore(deps): bump clap from 4.5.51 to 4.5.52 (#74)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.51 to 4.5.52.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.51...clap_complete-v4.5.52)

---
updated-dependencies:
- dependency-name: clap
  dependency-version: 4.5.52
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-18 18:22:05 +01:00
dependabot[bot]
f5ebb62c9e chore(deps): bump http_req from 0.14.1 to 0.14.2 (#75)
Bumps [http_req](https://github.com/jayjamesjay/http_req) from 0.14.1 to 0.14.2.
- [Release notes](https://github.com/jayjamesjay/http_req/releases)
- [Commits](https://github.com/jayjamesjay/http_req/compare/v0.14.1...v0.14.2)

---
updated-dependencies:
- dependency-name: http_req
  dependency-version: 0.14.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-18 18:21:46 +01:00
Marco Cadetg
dda39e5cdf feat: add TCP network analytics with retransmission detection (#72)
Adds real-time TCP connection quality monitoring:
- Retransmission detection via sequence number analysis
- Out-of-order packet tracking
- Fast retransmit detection (RFC 2581)
- Per-connection and aggregate statistics
- Network Stats panel in UI
- Platform-independent implementation using pcap data

Statistics show both active (current connections) and total
(cumulative) counts. Individual connection details display
per-connection metrics for troubleshooting network issues.
2025-11-14 12:38:38 +01:00
Marco Cadetg
8822af9793 chore: update README.md a bit 2025-11-02 20:13:51 +01:00
Marco Cadetg
e1917b6ea2 fix: linux tests 2025-11-02 20:13:32 +01:00
Marco Cadetg
dc32e4a9f5 Add Homebrew installation instructions to README
Added Homebrew installation instructions for macOS and Linux.
2025-11-02 19:52:42 +01:00
Marco Cadetg
85b2662c85 feat: add freebsd (#71)
* feat: add freebsd
2025-11-02 19:47:26 +01:00
Marco Cadetg
03cc04624f chore: cleanup dead code 2025-10-31 14:31:07 +01:00