How to find out the IP range for a certain country code in python?

222 views Asked by At

Is there a way to figure out the IP ranges for a certain country code without using MaxMind or IP2Location where in both they provide a binary file where one have to check single IP at a time

both source do not provide a way to list the ranges for a certain country

1

There are 1 answers

1
Michael C. On BEST ANSWER

They do provide data files in CSV / text format. See example below.

https://www.ip2location.com/samples/db1-ip-country.txt