Created
June 4, 2016 05:42
-
-
Save r-k-b/e04317694cc8412cf63b5b5b8e3c998c to your computer and use it in GitHub Desktop.
Show me my public IP address, and basic details of the ISP for same.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
WANIP="$(dig +short myip.opendns.com @resolver1.opendns.com)" && | |
echo "Wan IP: ${WANIP}" && | |
whois $WANIP | grep -iE -e 'netname:' -e 'e-mail:' -e 'irt:' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment