Skip to content

Tags: rekurt/prt

Tags

v0.5.0

Toggle v0.5.0's commit message
Release v0.5.0

v0.3.3

Toggle v0.3.3's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Merge pull request #5 from rekurt/claude/kind-clarke

Improve repository SEO and community health

v0.3.2

Toggle v0.3.2's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Merge pull request #3 from rekurt/feat/propose-fix-for-terminal-escap…

…e-injection

fix: sanitize process detail strings before tui rendering

v0.3.1

Toggle v0.3.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Merge pull request #2 from rekurt/feat/v0.3.1

chore: unify crate versions via workspace.package

v0.3.0

Toggle v0.3.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
feat: v0.3.0 — alerts, firewall, containers, tracing, and fullscreen …

…views

## Summary

Major v0.3.0 release: 16 new features across monitoring, security,
containers, and navigation — plus critical bug fixes for lsof parsing.

## New Features

### Monitoring & Alerts
- **Alerts engine** — configurable rules with `highlight` / `bell` actions
- **Bandwidth tracking** — per-entry RX/TX deltas via `BandwidthTracker`
- **Suspicious detection** — heuristics for unusual outbound connections
- **Known ports DB** — ~170 well-known services + user overrides from TOML

### Security & Networking
- **Firewall integration** — block remote IPs via pf (macOS) / iptables (Linux)
- **strace/dtruss** — attach/detach tracer to selected PID
- **SSH port forwarding** — interactive tunnel creation with `ForwardManager`
- **Container awareness** — resolve Docker/Podman container names per PID
- **Linux namespaces** — dedicated view for net-namespace isolation

### Views & Navigation
- **Fullscreen views** (keys 4–7): Chart, Topology, ProcessDetail, Namespaces
- **Process detail cache** — avoids per-frame procfs re-reads
- **Focus stability** — selection tracked by `(port, pid)` identity across refreshes
- **Gone-entry retention** — 5s visibility for disappeared connections

### CLI & Config
- **`--json` streaming** — NDJSON output, one entry per scan cycle
- **`watch` subcommand** — compact UP/DOWN monitor with BEL on changes
- **TOML config** — `~/.config/prt/config.toml` for rules, known ports, overrides

## Bug Fixes

- **Fix UDP protocol detection** — `lsof -F` output never contained `"UDP"`
  in the `n` field, so all UDP connections were classified as TCP. Added `P`
  field to lsof flags and parse protocol explicitly.
- **Fix TCP state parsing** — `TST=LISTEN` arrives AFTER the `n` line in lsof
  `-F` output; parser now buffers address and flushes on fd/process boundary.
- **Fix sort performance** — `sort_entries` was allocating strings on every
  comparison; added `Ord` to `Protocol`/`ConnectionState` enums.
- **Fix i18n gaps** — translated `iface_bind`, localized `fmt_kill_sent` /
  `fmt_sudo_error`, aligned `conn_process` padding in ru.rs.
- **Remove unused `arboard` dep** from prt-core (only used in TUI crate).

## Test Plan

- [x] `cargo build --workspace` passes
- [x] `cargo test --workspace` — all 79 tests pass
- [x] `cargo clippy --workspace --all-targets` — no warnings
- [x] `cargo fmt --all -- --check` passes
- [x] Runtime check on macOS: LISTEN/ESTABLISHED/CLOSED states correctly
      displayed, UDP entries properly labeled (UNKNOWN state is expected for UDP)
- [x] `--export json` produces valid JSON with correct state distribution
- [ ] Runtime check on Linux (requires Linux environment)
- [ ] Verify alerts fire on test rule configuration
- [ ] Verify firewall block requires sudo and produces undo command

## Breaking Changes

`prt-core` public API significantly expanded. New modules:
`config`, `known_ports`, `core::{alerts, firewall, container, namespace,
process_detail, bandwidth, suspicious}`. `Session` gained public `config`
and `bandwidth` fields.

v0.2.0

Toggle v0.2.0's commit message
Release v0.2.0 — SEO, crate READMEs, uzers migration, publish workflow