Created
March 12, 2019 10:33
-
-
Save briandemant/3adf0cea70af23ebf3c19366900fe7e0 to your computer and use it in GitHub Desktop.
get current public ip ranges's for google cloud
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
for x in $(nslookup -q=TXT _cloud-netblocks.googleusercontent.com 8.8.8.8| egrep -o "include:_cloud[-.a-z0-9]*" | cut -c9-);do | |
nslookup -q=TXT $x 8.8.8.8 | egrep -o 'ip4:[./0-9]*' | cut -c5- | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment