Getting the list of IP address ranges for a specific AWS Region

Amazon just published a JSON file with the details of the IP Address ranges used on each region and service.

jq can be used to get the list of ranges for a specific AWS Region and service.

curl -s https://ip-ranges.amazonaws.com/ip-ranges.json | jq -r '.prefixes[] | select(.region | contains("us-east-1")) | select(.service | contains("EC2"))  | .ip_prefix'
50.19.0.0/16
75.101.128.0/17
54.208.0.0/15
54.172.0.0/15
50.16.0.0/15
54.156.0.0/14
174.129.0.0/16
54.92.128.0/17
54.224.0.0/15
72.44.32.0/19
184.73.0.0/16
54.204.0.0/15
54.160.0.0/13
54.196.0.0/15
54.210.0.0/15
184.72.128.0/17
216.182.224.0/20
54.144.0.0/14
54.198.0.0/16
54.88.0.0/14
54.226.0.0/15
54.234.0.0/15
54.242.0.0/15
204.236.192.0/18
67.202.0.0/18
54.174.0.0/15
107.20.0.0/14
54.236.0.0/15
54.221.0.0/16
184.72.64.0/18
54.80.0.0/13
23.20.0.0/14

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s