maxmind/geoip-api-java

LookupService.getOrg for GeoIPASNum.dat sometimes throws an ArrayIndexOutOfBoundsException

Closed this issue · 1 comments

Running geoip-api-java/examples/ASNumLookup with the IP address 203.155.47.1 or 27.254.8.1 as input, will result in the following stack trace:

Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 300
    at com.maxmind.geoip.LookupService.getOrg(LookupService.java:907)
    at com.maxmind.geoip.LookupService.getOrg(LookupService.java:864)
    at com.maxmind.geoip.LookupService.getOrg(LookupService.java:874)
    at ASNumLookup.main(ASNumLookup.java:13)

The latest source code from https://github.com/maxmind/geoip-api-java.git have been used. The latest version of the database have also been used:

BTW, will the GeoIPASNum database be available in GeoLite2 format (and the new API can be used)?

/Tor

Thanks for reporting this. I confirmed the issue locally.

As for the GeoLite2 release, it may be a few months yet. We are slowly rolling out the new databases.