Contents

List open ports on OSX

Contents

List open ports on OSX

To list the open ports on OSX we need to use the lsof (list open files) tool. At the the end of of the day pretty much everything is a file handle in a unix kernel. The following example show how invoke the tool and filter out the important bits:

lsof -i -n -P | grep TCP | grep LISTEN