[data] Update DigitalOcean IPs
This commit is contained in:
@ -82,6 +82,7 @@
|
||||
137.184.248.0/22
|
||||
137.184.252.0/24
|
||||
137.184.254.0/24
|
||||
137.184.255.0/24
|
||||
137.184.32.0/20
|
||||
137.184.48.0/20
|
||||
137.184.64.0/20
|
||||
|
@ -1,5 +1,5 @@
|
||||
--- digitalocean_ips.txt 2023-07-23 13:23:19.965958629 +0200
|
||||
+++ digitalocean_announced_ips.txt 2023-07-23 13:23:42.073737375 +0200
|
||||
--- digitalocean_ips.txt 2023-08-12 11:11:29.768794468 +0200
|
||||
+++ digitalocean_announced_ips.txt 2023-08-12 11:11:51.656777015 +0200
|
||||
@@ -1,6 +1,4 @@
|
||||
-103.253.145.0/24
|
||||
-103.253.146.0/24
|
||||
@ -136,15 +136,17 @@
|
||||
128.199.0.0/20
|
||||
128.199.128.0/18
|
||||
128.199.16.0/20
|
||||
@@ -197,6 +80,7 @@
|
||||
@@ -197,7 +80,9 @@
|
||||
137.184.240.0/22
|
||||
137.184.244.0/22
|
||||
137.184.248.0/22
|
||||
+137.184.252.0/24
|
||||
137.184.254.0/24
|
||||
+137.184.255.0/24
|
||||
137.184.32.0/20
|
||||
137.184.48.0/20
|
||||
@@ -244,6 +128,9 @@
|
||||
137.184.64.0/20
|
||||
@@ -244,6 +129,9 @@
|
||||
138.68.208.0/20
|
||||
138.68.224.0/20
|
||||
138.68.240.0/20
|
||||
@ -154,7 +156,7 @@
|
||||
138.68.36.0/22
|
||||
138.68.40.0/21
|
||||
138.68.48.0/20
|
||||
@@ -252,8 +139,7 @@
|
||||
@@ -252,8 +140,7 @@
|
||||
138.68.96.0/20
|
||||
139.59.0.0/20
|
||||
139.59.112.0/20
|
||||
@ -164,7 +166,7 @@
|
||||
139.59.160.0/20
|
||||
139.59.16.0/20
|
||||
139.59.176.0/20
|
||||
@@ -326,8 +212,11 @@
|
||||
@@ -326,8 +213,11 @@
|
||||
143.244.204.0/22
|
||||
143.244.208.0/22
|
||||
143.244.212.0/22
|
||||
@ -176,7 +178,7 @@
|
||||
144.126.192.0/20
|
||||
144.126.208.0/20
|
||||
144.126.224.0/20
|
||||
@@ -335,62 +224,9 @@
|
||||
@@ -335,62 +225,9 @@
|
||||
144.126.244.0/22
|
||||
144.126.248.0/22
|
||||
144.126.252.0/22
|
||||
@ -242,7 +244,7 @@
|
||||
146.185.184.0/21
|
||||
146.190.0.0/22
|
||||
146.190.112.0/20
|
||||
@@ -538,6 +374,13 @@
|
||||
@@ -538,6 +375,13 @@
|
||||
159.89.252.0/22
|
||||
159.89.32.0/20
|
||||
159.89.48.0/21
|
||||
@ -256,7 +258,7 @@
|
||||
159.89.64.0/20
|
||||
159.89.80.0/20
|
||||
159.89.96.0/20
|
||||
@@ -560,241 +403,14 @@
|
||||
@@ -560,241 +404,14 @@
|
||||
161.35.64.0/20
|
||||
161.35.80.0/20
|
||||
161.35.96.0/20
|
||||
@ -505,7 +507,7 @@
|
||||
163.47.8.0/22
|
||||
164.90.128.0/20
|
||||
164.90.144.0/20
|
||||
@@ -805,6 +421,9 @@
|
||||
@@ -805,6 +422,9 @@
|
||||
164.90.224.0/20
|
||||
164.90.240.0/22
|
||||
164.90.244.0/22
|
||||
@ -515,7 +517,7 @@
|
||||
164.90.252.0/22
|
||||
164.92.128.0/20
|
||||
164.92.144.0/20
|
||||
@@ -916,6 +535,7 @@
|
||||
@@ -916,6 +536,7 @@
|
||||
167.99.80.0/20
|
||||
167.99.96.0/20
|
||||
170.64.128.0/18
|
||||
@ -523,7 +525,7 @@
|
||||
170.64.248.0/21
|
||||
174.138.0.0/20
|
||||
174.138.100.0/22
|
||||
@@ -954,10 +574,7 @@
|
||||
@@ -954,10 +575,7 @@
|
||||
178.62.128.0/18
|
||||
178.62.192.0/18
|
||||
178.62.64.0/18
|
||||
@ -535,7 +537,7 @@
|
||||
188.166.0.0/18
|
||||
188.166.128.0/22
|
||||
188.166.132.0/22
|
||||
@@ -975,201 +592,13 @@
|
||||
@@ -975,201 +593,13 @@
|
||||
188.166.224.0/20
|
||||
188.166.240.0/20
|
||||
188.166.64.0/18
|
||||
@ -744,7 +746,7 @@
|
||||
192.34.56.0/24
|
||||
192.34.57.0/24
|
||||
192.34.58.0/24
|
||||
@@ -1178,6 +607,7 @@
|
||||
@@ -1178,6 +608,7 @@
|
||||
192.34.61.0/24
|
||||
192.34.62.0/24
|
||||
192.34.63.0/24
|
||||
@ -752,7 +754,7 @@
|
||||
192.81.208.0/24
|
||||
192.81.209.0/24
|
||||
192.81.210.0/24
|
||||
@@ -1186,108 +616,21 @@
|
||||
@@ -1186,108 +617,21 @@
|
||||
192.81.213.0/24
|
||||
192.81.214.0/24
|
||||
192.81.215.0/24
|
||||
@ -876,7 +878,7 @@
|
||||
204.48.16.0/20
|
||||
206.189.0.0/20
|
||||
206.189.112.0/20
|
||||
@@ -1314,23 +657,23 @@
|
||||
@@ -1314,23 +658,23 @@
|
||||
207.154.208.0/20
|
||||
207.154.224.0/20
|
||||
207.154.240.0/20
|
||||
@ -906,7 +908,7 @@
|
||||
24.144.64.0/22
|
||||
24.144.96.0/19
|
||||
24.199.112.0/20
|
||||
@@ -1339,175 +682,23 @@
|
||||
@@ -1339,175 +683,23 @@
|
||||
24.199.72.0/21
|
||||
24.199.80.0/20
|
||||
24.199.96.0/20
|
||||
@ -1099,7 +1101,7 @@
|
||||
45.55.0.0/19
|
||||
45.55.100.0/22
|
||||
45.55.104.0/22
|
||||
@@ -1522,16 +713,18 @@
|
||||
@@ -1522,16 +714,18 @@
|
||||
45.55.64.0/19
|
||||
45.55.96.0/22
|
||||
46.101.0.0/18
|
||||
@ -1122,7 +1124,7 @@
|
||||
5.101.96.0/21
|
||||
64.225.0.0/20
|
||||
64.225.112.0/20
|
||||
@@ -1563,6 +756,8 @@
|
||||
@@ -1563,6 +757,8 @@
|
||||
67.205.144.0/20
|
||||
67.205.160.0/20
|
||||
67.205.176.0/20
|
||||
@ -1131,7 +1133,7 @@
|
||||
67.207.68.0/22
|
||||
67.207.72.0/22
|
||||
67.207.76.0/22
|
||||
@@ -1589,90 +784,6 @@
|
||||
@@ -1589,90 +785,6 @@
|
||||
69.55.49.0/24
|
||||
69.55.54.0/24
|
||||
69.55.55.0/24
|
||||
|
@ -2,34 +2,6 @@
|
||||
|
||||
set -eux
|
||||
|
||||
UA="$1"
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
echo 'Missing the user agent as a first argument'
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
# Fetch digitalocean declared IPs
|
||||
#curl https://digitalocean.com/geo/google.csv -s -L -# -o - | cut -d ',' -f 1 | sort | uniq > digitalocean_ips.txt
|
||||
|
||||
# List all routable routes for the AS 14061
|
||||
#curl https://bgp.tools/table.txt -A "$UA" -s | grep -e ' 14061$' | wc -l
|
||||
|
||||
# Fetch all announced IPs
|
||||
#curl https://bgp.tools/table.txt -A "$UA" -s | grep -e ' 14061$' | cut -d ' ' -f 1 | sort | uniq > digitalocean_announced_ips.txt
|
||||
|
||||
# Compare the declared IPs and announced IPs
|
||||
#diff -u digitalocean_ips.txt digitalocean_announced_ips.txt > digitalocean_ips_vs_announced_ips.diff
|
||||
|
||||
# Generate the full IP list to check PTRs
|
||||
#grep -v -F ":" digitalocean_announced_ips.txt | xargs -n1 prips > digitalocean_announced_ips_full.txt
|
||||
|
||||
# Some test command to get all declared reverse DNS objects at RIPE
|
||||
#curl 'https://apps.db.ripe.net/db-web-ui/api/rest/fulltextsearch/select?format=json&rows=10000&q=(nserver:(digitalocean.com))%20AND%20(object-type:domain)' -H 'Accept: application/json' -A "$UA" | jq -r '.result.docs | map(.doc.strs) | .[] | map(select(.str.name=="domain")) | map(.str.value) | .[] ' > digitalocean_announced_reverse_dns.txt
|
||||
|
||||
# Build IPs CIDRs with found reverse DNS servers
|
||||
#grep -v -F ":" digitalocean_announced_ips.txt | xargs -I {} sh -c "cidr="$(echo '{}' | cut -d '/' -f 1)"; dig +nocomments -x \$cidr | grep -v -F ';' | grep -e '.*\.in-addr\.arpa\.' | echo '{}'" > digitalocean_announced_ips_with_reverse.txt
|
||||
|
||||
grep -v -F ":" digitalocean_announced_ips.txt | xargs -I {} sh -c "echo '{} # $(dig +short -x {})'" > digitalocean_announced_ips_with_reverse.txt
|
||||
|
||||
|
||||
|
35
digitalocean/update-announced-ips.sh
Executable file
35
digitalocean/update-announced-ips.sh
Executable file
@ -0,0 +1,35 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -eu
|
||||
|
||||
if [ -z "${1:-}" ]; then
|
||||
echo 'Missing the user agent as a first argument'
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
UA="$1"
|
||||
|
||||
set -x
|
||||
|
||||
cd ./digitalocean/
|
||||
|
||||
# Fetch digitalocean declared IPs
|
||||
curl https://digitalocean.com/geo/google.csv -s -L -# -o - | cut -d ',' -f 1 | sort | uniq > digitalocean_ips.txt
|
||||
|
||||
# List all routable routes for the AS 14061
|
||||
curl https://bgp.tools/table.txt -A "$UA" -s | grep -e ' 14061$' | wc -l
|
||||
|
||||
# Fetch all announced IPs
|
||||
curl https://bgp.tools/table.txt -A "$UA" -s | grep -e ' 14061$' | cut -d ' ' -f 1 | sort | uniq > digitalocean_announced_ips.txt
|
||||
|
||||
# Compare the declared IPs and announced IPs
|
||||
diff -u digitalocean_ips.txt digitalocean_announced_ips.txt > digitalocean_ips_vs_announced_ips.diff
|
||||
|
||||
# Generate the full IP list to check PTRs
|
||||
grep -v -F ":" digitalocean_announced_ips.txt | xargs -n1 prips > digitalocean_announced_ips_full.txt
|
||||
|
||||
# Some test command to get all declared reverse DNS objects at RIPE
|
||||
#curl 'https://apps.db.ripe.net/db-web-ui/api/rest/fulltextsearch/select?format=json&rows=10000&q=(nserver:(digitalocean.com))%20AND%20(object-type:domain)' -H 'Accept: application/json' -A "$UA" | jq -r '.result.docs | map(.doc.strs) | .[] | map(select(.str.name=="domain")) | map(.str.value) | .[] ' > digitalocean_announced_reverse_dns.txt
|
||||
|
||||
# Build IPs CIDRs with found reverse DNS servers
|
||||
grep -v -F ":" digitalocean_announced_ips.txt | xargs -I {} sh -c "cidr="$(echo '{}' | cut -d '/' -f 1)"; dig +nocomments -x \$cidr | grep -v -F ';' | grep -e '.*\.in-addr\.arpa\.' | echo '{}'" > digitalocean_announced_ips_with_reverse.txt
|
Reference in New Issue
Block a user