DEV Community

Discussion on: Gaining remote access to a computer with a reverse shell attack in Node.js

Collapse
 
ajoslin103 profile image
allen joslin

To see what ports are open on my Mac I use this script

#!/bin/bash
lsof -i -P | grep -i "listen"
Enter fullscreen mode Exit fullscreen mode

that list is usually small.

also if you have your firewall on (which you should) then the Mac will ask you if such-and-such should be allowed to listen for connections.

if I were asked if such&such should accept network connections while I was installing a package -- I'd say NO, delete the package, and post a note warning people.

Cheers!

Al;