Skip to content

Instantly share code, notes, and snippets.

@sarfarazahmad89
Created April 26, 2019 01:57
Show Gist options
  • Save sarfarazahmad89/e72a468f6506bc1d9265f78e892233cd to your computer and use it in GitHub Desktop.
Save sarfarazahmad89/e72a468f6506bc1d9265f78e892233cd to your computer and use it in GitHub Desktop.
How do you test you can connect to a utility without telnet lying around ?
>> for i in 5601 5602; do (</dev/tcp/my-machine.domain.com/$i) 2>/dev/null && echo "Can connect to port $i";done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment