Get country code of IPv4/IPv6 address. Address lookup is done offline.
Project description
IPToCC
Get ISO country code of IPv4/IPv6 address. Address lookup is done offline.
No external API call.
No paid GeoIP service.
Features
Thread-safe
Install
pip install IPToCC
Usage
import iptocc
country_code = iptocc.get_country_code('<IPv4/IPv6 address>')
Sources
ftp://ftp.afrinic.net/stats/afrinic/delegated-afrinic-extended-latest
ftp://ftp.arin.net/pub/stats/arin/delegated-arin-extended-latest
ftp://ftp.apnic.net/public/apnic/stats/apnic/delegated-apnic-extended-latest
ftp://ftp.lacnic.net/pub/stats/lacnic/delegated-lacnic-extended-latest
ftp://ftp.ripe.net/pub/stats/ripencc/delegated-ripencc-extended-latest
Libraries Used
References
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
IPToCC-1.0.5.tar.gz
(6.5 MB
view hashes)