NetOtter is a cross-platform packet listener and anlyser.
- C 96.2%
- Python 1.3%
- HTML 1.1%
- Shell 0.9%
- Makefile 0.4%
|
|
||
|---|---|---|
| includes | ||
| libs | ||
| src | ||
| tools | ||
| .gitignore | ||
| Makefile | ||
| README.md | ||
NetOtter
NetOtter is a packet sniffer for the terminal, written in C. It lists your network interfaces, captures on the ones you enable, and decodes each frame layer by layer: Ethernet, ARP, IPv4, IPv6, TCP, UDP, IGMP and MLD. Its analysis view names the hosts and the applications behind the traffic. It runs on Linux and Windows and reads the same capture files on both.
Features
- Live capture on Linux (raw
AF_PACKETsockets) and Windows (through Npcap). - Interactive or scripted: toggle interfaces and inspect packets from the keyboard, or capture in CLI mode until Ctrl-C.
- Display filters on addresses, ports, IP protocol, EtherType and "this machine" (
me), combined with OR or AND. - Analysis view: port names, hostnames learned passively from DNS answers, TLS SNI and QUIC Initial packets, app categories, and your own renamings.
- Save files (
.nto): compact, with compressed payloads. They keep the filters, the renamings and the learned names, and load the same on both systems. - Nothing sent behind your back: the only packets NetOtter ever sends are reverse DNS lookups. Each one is announced and logged, and
-Nturns them off. - Bounded memory: payloads are compressed into a temporary file, and the packet list has a RAM budget.
Build and install
Linux
Requirements: GCC, GNU make and OpenSSL's libcrypto.
make release # optimised, hardened build
make install # copies it to /usr/bin with cap_net_raw (asks for your password)
Windows
Install Npcap for live capture. Without it, NetOtter still opens and reads .nto files. Build with a 64-bit MinGW-w64 toolchain (WinLibs or MSYS2 UCRT64).
mingw32-make release
mingw32-make install :: for you only, in %LOCALAPPDATA%\Programs\NetOtter
mingw32-make install-admin :: for all users, in Program Files, added to PATH (admin prompt)
Quick start
netotter -l # list the interfaces and their ids
netotter -i 2 # capture on interface 2, interactive (h lists the commands)
netotter -c -i 2 -O capture # capture until Ctrl-C, then save to capture.nto
netotter -I capture.nto -c # print a saved capture
Documentation
The wiki has three sections:
- User guide: installation, options, commands, filters, the analysis view, save files.
- Developer documentation: architecture, the build, the save format and the function explorer.
- Learning: how Ethernet, IPv4, IPv6, TCP, UDP, QUIC and DNS packets are built, with real examples.