Linux Netstat (network statistics) utility
In computing, netstat (network statistics) is a command-line network utility that displays network connections for Transmission Control Protocol (both incoming and outgoing), routing tables, and a number of network interface (network interface controller or software-defined network interface) and network protocol statistics. Wikipedia.
Installation in Debian-like systems (Ubuntu, Kali Linux, ParrotSec OS, etc...):
sudo apt install net-tools -y
Display all sockets (default: connected):
netstat -a | more
Enumerate all TCP ports:
netstat -at
Enumerate all UDP ports:
netstat -au
Enumerate all locally running applications and its listen ports:
netstat -tlnp
Show process name and PID:
netstat -pt
Show all active connections:
netstat -t -n -v | grep ESTABLISHED
Support me on Patreon
#debian #linux #net-tools #netstat #network #tutorial #ubuntu