Skip to content

4.7.2 Configuration Ip2location Primary Lookup Method

Gurdeep Singh (Guru) edited this page Aug 12, 2024 · 2 revisions

Configuration - Ip2location - Primary Lookup Method

There are 2 lookup methods for ip2location that you can configure

  1. API (using ip2location.io API website)
  2. BIN file (downloaded from the ip2location or lite.ip2location website)

The default lookup method is set to API, which is via the ip2location.io API website. You can change the default method to use BIN as primary.

Via CLI

admin@phpterminal:firewall(config)# set ip2location primary lookup method 
...
OPTIONS: [API | BIN]

PRIMARY LOOKUP METHOD (API) : BIN

SET IP2LOCATION PRIMARY LOOKUP METHOD OUTPUT
...
FIREWALL DETAILS > IP2LOCATION_PRIMARY_LOOKUP_METHOD : BIN
...
admin@phpterminal:firewall(config)# 

Via PHP Firewall Class

$firewall->setIp2locationPrimaryLookupMethod('BIN');