Smarter by Design.Simpler for Business
Connection, Port & Scan
The Connection, Port & Scan group gathers the two commands that show the connections and the listening ports on the device, a scanner that probes the ports of a remote target, and a client that opens a manual TCP connection. The questions "Is this port being listened on?", "How many connections are open to the backend?", "Is 443 open on the target, or is it blocked on the way?" are the job of this group.
ss
Open connections, listening ports and a summary of the connection count.
→
netstat
Connections, the routing table and the interface statistics.
→
nmap
Which ports on a remote target are open, closed or filtered.
→
telnet
A manual TCP connection to a port; an interactive session.
→
Which Command When?
| Question | Command | Example |
|---|---|---|
| Which ports are being listened on in the selected route table, and which process holds them? | ss | sys-cmd ss -tlnp |
| How many established connections are there to the backend? | ss | sys-cmd ss -tn state established dst 10.20.0.30 |
| What are the routes of the route table? | netstat | sys-cmd netstat -rn |
| Is there an error or a dropped packet on the interfaces? | netstat | sys-cmd netstat -i |
| Are the ports on the target open or filtered? | nmap | sys-cmd nmap -Pn -p 80,443 10.20.0.30 |
| Connecting to the port and seeing the first response of the service manually | telnet | sys-cmd telnet 10.20.0.30 8080 |
Common Behavior
| Subject | Behavior |
|---|---|
| Writing | All four are tools with free parameters: everything written after the command name is passed to the tool as it is. |
| Context | All four run from within the selected v-device and route table: ss and netstat show the connections of that route table, and nmap and telnet connect to the target from that route table. |
| Restriction | In the ss command, the -F, --filter, -D and --diag parameters are rejected. |
| Interaction | telnet opens a full terminal session and cannot be connected to a pipe; the output of the other three commands can be filtered with |. |
| Recording | Every run is written to the user logs. |
All of the writing rules and the restrictions: System Commands.
