SS is utility used to investigate sockets in Linux and Unix systems. It shows information similar to netstat and able to dump socket statistics. ss command can display more than TCP and state information as compared to other tools. By default, ss displays a list of open non-listening sockets (e.g. TCP/UNIX/UDP) that have established a connection
Common options used with ss command are:
–n, –numeric <===> don’t resolve service names
-r, –resolve <===> resolve host hostnames.
-l, –listening <===> display listening sockets
-o, –options <===> show timer information
-e, –extended <===> show detailed socket information
-m, –memory <===> show socket memory usage
-p, –processes <===> show process using socket
–s, –summary <===> show socket usage summary
-N, –net <===> switch to the specified network namespace name
-4, –ipv4 <===> display only IP version 4 sockets
-6, –ipv6 <===> display only IP version 6 sockets
–0, –packet <===> display PACKET sockets
-t, –tcp <===> display only TCP sockets
-S, –sctp <===> display only SCTP sockets
-u, –udp <===> display only UDP sockets
-w, –raw <===> display only RAW sockets
-x, –unix <===> display only Unix domain sockets
-f, –family=FAMILY <===>- display sockets of type FAMILY
ss -t dst 192.168.1.10:443
<===> Show all sockets connecting to 192.168.1.10 on port 443ss -tun
<===> list tcp and udp ports with no hostname resolutionss -ltp
<===> Print process which owns the connectionss -lntp4
<===> ukáže spojení pouze IPv4 a TCP