id = "rustnet"
name = "RustNet"
homepage = "https://github.com/domcyrus/rustnet"
description = "Per-process network monitoring for your terminal with deep packet inspection, sandboxed by default."
executables = ["rustnet"]
[dotfiles]
paths = ["~/.config/rustnet/config.toml"]
secret = []
side_effect = false
[commands]
format = 1
label = "Monitor connections"
description = "Watch network connections per process in the TUI, or run headless and dump snapshots. Theme, GeoIP database paths, sandbox and logging switches are mostly left out."
quality = "ai-draft"
parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false }
[[commands.source]]
id = "usage"
kind = "help"
url = "https://github.com/domcyrus/rustnet/blob/main/USAGE.md"
revision = "2026-10-27"
evidence = """
-i, --interface <INTERFACE> Network interface to monitor
--show-localhost Show localhost connections (overrides default filtering)
--headless Run without the interactive terminal UI
--duration <SECONDS> Stop headless monitoring after this many seconds
--output <FORMAT> Headless output format: jsonl (stream snapshots) or
json (final snapshot)
--filter <QUERY> Filter headless output using the shared connection filter syntax
-r, --refresh-interval <MILLISECONDS> UI and headless snapshot refresh interval in milliseconds
--no-dpi Disable deep packet inspection
--no-resolve-dns Disable reverse DNS lookups (enabled by default)
--pcap-export <FILE> Export captured packets to PCAP file for Wireshark analysis
-f, --bpf-filter <FILTER> BPF filter expression for packet capture
"""
[[commands.field]]
id = "interface"
label = "Interface"
type = "string"
option = ["--interface", "-i"]
sources = ["usage"]
[[commands.field]]
id = "show_localhost"
label = "Show localhost connections"
type = "boolean"
option = ["--show-localhost"]
sources = ["usage"]
[[commands.field]]
id = "bpf_filter"
label = "BPF filter"
description = "Packet-capture filter expression, for example tcp port 443."
type = "string"
option = ["--bpf-filter", "-f"]
sources = ["usage"]
[[commands.field]]
id = "refresh_interval"
label = "Refresh interval (ms)"
type = "integer"
option = ["--refresh-interval", "-r"]
sources = ["usage"]
[[commands.field]]
id = "no_dpi"
label = "Disable deep packet inspection"
type = "boolean"
option = ["--no-dpi"]
sources = ["usage"]
[[commands.field]]
id = "no_resolve_dns"
label = "Disable reverse DNS"
type = "boolean"
option = ["--no-resolve-dns"]
sources = ["usage"]
[[commands.field]]
id = "headless"
label = "Headless"
description = "Run without the terminal UI and print snapshots."
type = "boolean"
option = ["--headless"]
sources = ["usage"]
[[commands.field]]
id = "duration"
label = "Duration (seconds)"
description = "Stop headless monitoring after this many seconds."
type = "integer"
option = ["--duration"]
sources = ["usage"]
[[commands.field]]
id = "output"
label = "Headless output format"
type = "enum"
option = ["--output"]
choices = [{ value = "jsonl", label = "JSON Lines (stream)" }, { value = "json", label = "JSON (final snapshot)" }]
sources = ["usage"]
[[commands.field]]
id = "filter"
label = "Headless filter"
type = "string"
option = ["--filter"]
sources = ["usage"]
[[commands.field]]
id = "pcap_export"
label = "PCAP export file"
type = "path"
option = ["--pcap-export"]
path = { kind = "file", role = "output" }
effect = "overwrite"
sources = ["usage"]
[[commands.task]]
id = "monitor"
label = "Monitor an interface"
fields = ["interface", "bpf_filter", "show_localhost", "no_dpi", "no_resolve_dns"]
[[commands.task]]
id = "snapshot"
label = "Headless snapshot"
set = { headless = [true] }
lock = ["headless"]
fields = ["interface", "headless", "duration", "output", "filter"]
required = ["duration"]
[[commands.task]]
id = "capture"
label = "Export a PCAP"
fields = ["interface", "bpf_filter", "pcap_export"]
required = ["pcap_export"]
[[commands.group]]
id = "basic"
label = "Basic"
fields = ["interface", "bpf_filter", "show_localhost", "headless", "duration", "output"]
[[commands.group]]
id = "advanced"
label = "Advanced"
fields = ["filter", "refresh_interval", "no_dpi", "no_resolve_dns", "pcap_export"]