Linux Open Port Scanning
As safety is always first you may want to find out if you have any back doors open in your system. One way to do this in linux is nmap. You can use the following commands:
- sudo nmap -sS -O 127.0.0.1
This will scan your system for any open tcp connections.
- sudo nmap -sU 127.0.0.1
This will do an udp port scan.
- sudo nmap -sS -O -p 20-25 127.0.0.1
You can scan for open port range with the command above
- sudo nmap -sS -F 127.0.0.1
Additionally this will do a fast limited tcp port scan
You can also do a scan for connection on a particular port and count them using the following command:
netstat -an | grep 80 | wc -l
Example of a port scan: