tokkonopapa / WordPress-IP-Geo-Block

A WordPress plugin that will blocks any comment, pingback and trackback spams posted from outside your nation. And it will also protect against malicious access to the login form, admin area and XML-RPC from undesired countries.
http://www.ipgeoblock.com/
29 stars 14 forks source link

Maxmind GeoIP and License key. #63

Open Neonapple opened 4 years ago

Neonapple commented 4 years ago

A license key/API key field is needed for maxmind GeoIP2.

Currently, the "class-maxmind-geolite2.php" file has to be modified manually to hard code the license key directly into the fetch URL such as:

define( 'IP_GEO_BLOCK_GEOLITE2_DB_IP',    'GeoLite2-Country.mmdb' );
define( 'IP_GEO_BLOCK_GEOLITE2_DB_ASN',   'GeoLite2-ASN.mmdb'     );
define( 'IP_GEO_BLOCK_GEOLITE2_ZIP_IP',   'https://download.maxmind.com/app/geoip_download?edition_id=GeoLite2-Country&license_key=XXXXXXXXXXX&suffix=tar.gz' );
define( 'IP_GEO_BLOCK_GEOLITE2_ZIP_ASN',  'https://download.maxmind.com/app/geoip_download?edition_id=GeoLite2-ASN&license_key=XXXXXXXXXXX&suffix=tar.gz'     );
define( 'IP_GEO_BLOCK_GEOLITE2_DOWNLOAD', 'https://dev.maxmind.com/geoip/geoip2/geolite2/' );