Created
February 16, 2015 15:20
-
-
Save aaronmelton/5edcb8006df3b7dae6ea to your computer and use it in GitHub Desktop.
This script uses native whois command to return the WHOIS information of the IP Addresses provided.
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
#!/usr/bin/sh | |
# | |
# downloadWHOIS.sh | |
# | |
# This script uses native whois command to return the WHOIS information | |
# of the IP Addresses provided. | |
# | |
# USAGE: | |
# $ ./downloadWHOIS.sh 1.2.3.4 | |
# $ ./downloadWHOIS.sh 1.2.3.4 1.2.3.5 1.2.3.6 etc. | |
# | |
# Set path to save files: | |
path=/Downloads/ | |
# Set filename prefix and/or suffix: | |
prefix= | |
suffix=\_whois.txt | |
for args in "$@" | |
do | |
whois $args > $path$prefix$args$suffix | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment