Linux Security: List Listening Ports
There are a few ways to list all ports open and to show which daemons are listening. Simply run one of the two commands:
# lsof -i | grep "(LISTEN)"
Example output
-or-
# netstat -tupan | grep "LISTEN"
I believe this to be a cleaner output ![]()
Categories: Linux