Skip to content
/ nsd Public

NSD (Network Sniffing Dashboard) is a powerful, cross-platform network traffic monitoring tool with a modern terminal UI inspired by btop. Monitor real-time network statistics, visualize traffic patterns, analyze connections, and detect anomalies - all from your terminal. Features packet capture via libpcap, customizable themes, and plugin support.

License

Notifications You must be signed in to change notification settings

perplext/nsd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NSD - Network Sniffing Dashboard

CI

A cross-platform network sniffing dashboard with a terminal UI similar to btop. NSD allows users to view network statistics and drill down into individual connections.

UI Preview

Check out the docs/ui_preview.txt file for a preview of the terminal UI, including the network traffic visualization graphs.

Features

  • Real-time network traffic statistics
  • Visual graphs for network traffic ingress and egress
  • Static gradient shading for graph fills (toggleable via --gradient flag)
  • Custom theme loading from JSON/YAML via --theme-file flag
  • Detailed connection information (source, destination, protocol, etc.)
  • Interactive terminal UI with btop-like look and feel
  • Promiscuous mode for capturing all network traffic
  • Extensive cross-platform support:
    • Linux: amd64, 386, arm64, armv7, armv6 (Raspberry Pi), mips/mipsle, ppc64le, s390x
    • macOS: Intel and Apple Silicon
    • Windows: amd64, 386, arm64
    • BSD: FreeBSD, OpenBSD, NetBSD, DragonFlyBSD

Requirements

Installation

# Clone the repository
git clone https://github.com/perplext/nsd.git
cd nsd

# Build the application
go build -o nsd ./cmd/nsd
# Or use make
make build

# Build for all platforms
make build-all

# Run the application (requires root/administrator privileges)
sudo ./bin/nsd

Usage

# Basic usage
sudo nsd

# Specify a network interface
sudo ./nsd -i eth0

# Specify a theme
sudo ./nsd -theme "High-Contrast Dark"

# Disable static gradient shading
sudo ./nsd -gradient=false

# Load custom theme
sudo ./nsd --theme-file /path/to/custom_theme.json

# Help information
./nsd -h

Plugin System

NSD can load Go-based plugins at runtime using the --plugins flag. Plugins must be compiled as Go plugins (.so) with:

cd examples/simpleplugin
go build -buildmode=plugin -o simpleplugin.so simpleplugin.go

Then start NSD with your plugin:

sudo ./nsd --plugins examples/simpleplugin/simpleplugin.so

The provided SimplePlugin logs the packet buffer length every 10 seconds.

Protocol Filtering & Charting

NSD supports live protocol-level filtering and usage charting:

  • Press b to set a BPF filter (e.g. tcp and port 80) during capture.
  • Press p to view and auto-refresh the raw packet buffer.
  • The protocol usage panel on the right shows a real-time breakdown (%) of observed protocols with horizontal bars.
  • Press h to view a packet-size histogram.
  • Press d to view HTTP/DNS packet counts.
  • Press g to view remote IP geo-mapping.

Localization

NSD supports localization of CLI messages and UI labels via JSON translation files. Use the --i18n-file flag to load translations:

sudo ./nsd --i18n-file /path/to/translations.json

Your JSON file should map message keys to translated strings, for example:

{
  "requires_root": "Ce programme nécessite des privilèges root pour capturer des paquets.",
  "run_as_root": "Exécutez avec sudo ou en tant qu'administrateur."
}

Unrecognized keys fall back to the original English text.

Security and Ethics

This tool is designed for network administrators and security professionals to monitor networks they own or have explicit permission to monitor. Always ensure you have proper authorization before monitoring any network.

WARNING: Unauthorized network monitoring may be illegal in many jurisdictions and violate privacy laws.

Testing

Run unit tests:

go test ./pkg/netcap

Continuous Integration

We use GitHub Actions to build and test NSD on Linux, macOS, and Windows. The CI workflow is defined in .github/workflows/ci.yml.

License

MIT

About

NSD (Network Sniffing Dashboard) is a powerful, cross-platform network traffic monitoring tool with a modern terminal UI inspired by btop. Monitor real-time network statistics, visualize traffic patterns, analyze connections, and detect anomalies - all from your terminal. Features packet capture via libpcap, customizable themes, and plugin support.

Topics

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •