echo > /dev/tcp/[host]/[port] && echo “Port is open”
or
echo > /dev/udp/[host]/[port] && echo “Port is open”
reference: https://www.fosslinux.com/35730/5-ways-to-check-if-a-port-is-open-on-a-remote-linux-pc.htm
[linux] check remote port if open
分類:linux