| Crates.io | ntap |
| lib.rs | ntap |
| version | 0.9.0 |
| created_at | 2024-05-31 13:22:11.053215+00 |
| updated_at | 2025-08-10 05:43:56.470305+00 |
| description | Network traffic monitor/analyzer |
| homepage | https://github.com/shellrow/ntap |
| repository | https://github.com/shellrow/ntap |
| max_upload_size | |
| id | 1258034 |
| size | 321,687 |
Network traffic monitor/analyzer, for Linux, macOS, and Windows.
ntap provides comprehensive insights into your network's activity, enabling users to monitor traffic, manage connections, and view network configurations with ease.
See usage
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/shellrow/ntap/releases/latest/download/ntap-installer.sh | sh
irm https://github.com/shellrow/ntap/releases/latest/download/ntap-installer.ps1 | iex
You can download archives of precompiled binaries from the releases
cargo install ntap
Or you can use binstall for install ntap from github release.
cargo binstall ntap
First, clone the repository:
git clone https://github.com/shellrow/ntap
Then, build the project:
cd ntap
cargo build --release
./target/release/ntap
The following post-install configuration steps are applicable to both the CLI version (ntap) and the desktop application (ntap-desktop).
These steps ensure that ntap has the necessary permissions and environment setup to function correctly on different operating systems.
ntap requires elevated privileges to monitor network packets effectively. On Linux, you can configure these privileges using two main methods:
setcapGranting capabilities to the ntap binary allows it to operate with the necessary privileges without requiring sudo for each execution.
This method is recommended for single-user machines or in environments where all users are trusted.
Assign necessary capabilities to the ntap binary
sudo setcap 'cap_sys_ptrace,cap_dac_read_search,cap_net_raw,cap_net_admin+ep' $(command -v ntap)
Run ntap as an unprivileged user:
ntap
cap_sys_ptrace,cap_dac_read_search: Allows ntap to access /proc/<pid>/fd/ to identify which open port belongs to which process.cap_net_raw,cap_net_admin: Enables packet capturing capabilities.sudo (for multi-user environments)For environments with multiple users, requiring privilege escalation each time ntap is run can enhance security.
sudo ntap
On macOS, managing access to the Berkeley Packet Filter (BPF) devices is necessary for ntap to monitor network traffic:
chmod-bpf to automatically manage permissions for BPF devices:Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/shellrow/chmod-bpf/releases/latest/download/chmod-bpf-installer.sh | sh
Install prebuilt binaries via Homebrew
brew install shellrow/tap-chmod-bpf/chmod-bpf
chmod-bpf check
sudo chmod-bpf install
ntap is released under the MIT License. See the LICENSE file for more details.