Test a port without telnet

Traditionally you’d use telnet to check a port. But bash now has that capability. Use:

cat < /dev/tcp/

And here’s how to do it the nc way:

Single port:

nc -zv 80

Multiple ports:

nc -zv 22 80 8080

Range of ports:

nc -zv 20-30



Leave a Reply

Your email address will not be published. Required fields are marked *