mirror of
git://git.code.sf.net/p/xtables-addons/xtables-addons
synced 2025-09-20 11:34:57 +02:00
geoip: adapt to GeoLite2 database
Requires Net::CIDR::Lite for manipulating CIDR blocks, aggregation, etc. since database is stored as subnet/mask pairs and may require compaction into ranges (which can combine adjacent subnets). We don't use Net::CIDR because it's a clunkier interface. Signed-off-by: Philip Prindeville <philipp@redfish-solutions.com>
This commit is contained in:

committed by
Jan Engelhardt

parent
b91dbd03c7
commit
256ac1a4f6
@@ -1,8 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
rm -f GeoIPv6.csv GeoIPv6.csv.gz GeoIPCountryCSV.zip GeoIPCountryWhois.csv;
|
||||
wget \
|
||||
http://geolite.maxmind.com/download/geoip/database/GeoIPv6.csv.gz \
|
||||
http://geolite.maxmind.com/download/geoip/database/GeoIPCountryCSV.zip;
|
||||
gzip -d GeoIPv6.csv.gz;
|
||||
unzip GeoIPCountryCSV.zip;
|
||||
rm -rf GeoLite2-Country-CSV_*
|
||||
|
||||
wget -q http://geolite.maxmind.com/download/geoip/database/GeoLite2-Country-CSV.zip
|
||||
unzip -q GeoLite2-Country-CSV.zip
|
||||
rm -f GeoLite2-Country-CSV.zip
|
||||
|
Reference in New Issue
Block a user