maxmind / mmdbinspect

look up records for one or more IPs/networks in one or more .mmdb databases
Apache License 2.0
135 stars 14 forks source link

GeoIP2 Anonymous IP database support #64

Closed mahadevan-karthi-dwp closed 6 months ago

mahadevan-karthi-dwp commented 6 months ago

Hi, Does this support GeoIP2 Anonymous IP database ?

I tried and it did not return any values.

./mmdbinspect -include-aliased-networks -db ~/Downloads/GeoIP2-Anonymous-IP.mmdb 100.35.239.250
[
    {
        "Database": "/Users/myusernamei/Downloads/GeoIP2-Anonymous-IP.mmdb",
        "Records": [
            {
                "Network": "100.35.239.250/13",
                "Record": {}
            }
        ],
        "Lookup": "100.35.239.250"
    }
]
blakeyjason commented 6 months ago

Yes, mmdbinspect can be used to query the Anonymous-IP mmdb.

You can verify that it does retrieve records by running:

mmdbinspect -db GeoIP2-Anonymous-IP.mmdb 0.0.0.0/0

which will return many records, some having values like this (the 1.1.1.1 IP is not an actual, valid IP):

            {
                "Network": "1.1.1.1/32",
                "Record": {
                    "is_anonymous": true,
                    "is_residential_proxy": true
                }
            },