Bug 1576034 - stock configuration causes geoipupdate to fail
Summary: stock configuration causes geoipupdate to fail
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: geoipupdate
Version: 27
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Paul Howarth
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-05-08 15:46 UTC by Roy A. Gilmore
Modified: 2018-07-19 17:49 UTC (History)
3 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2018-05-19 21:34:21 UTC


Attachments (Terms of Use)

Description Roy A. Gilmore 2018-05-08 15:46:18 UTC
Description of problem:
Stock configuration file (/etc/GeoIP.conf) causes geoipupdate to fail with "Invalid user ID"

Version-Release number of selected component (if applicable):
geoipupdate-2.4.0-3.fc27.x86_64

How reproducible:
Every time

Steps to Reproduce:
1. [root@thor ~]# geoipupdate -v

Actual results:
geoipupdate 2.4.0
Opened License file /etc/GeoIP.conf
UserId 0
LicenseKey 000000000000
Insert product_id 506
Insert product_id 517
Insert product_id 533
Read in license key /etc/GeoIP.conf
Number of product ids 3
url: https://updates.maxmind.com/app/update_getfilename?product_id=506
md5hex_digest: 8ef41798df108ce9bd41382c9721b1c9
url: https://updates.maxmind.com/app/update_getipaddr
Client IP address: 108.244.34.97
md5hex_digest2 (challenge): 35fed0a4d3098563e8a7804ce424218c
url: https://updates.maxmind.com/app/update_secure?db_md5=8ef41798df108ce9bd41382c9721b1c9&challenge_md5=35fed0a4d3098563e8a7804ce424218c&user_id=0&edition_id=506
Received an unexpected HTTP status code of 401 from https://updates.maxmind.com/app/update_secure?db_md5=8ef41798df108ce9bd41382c9721b1c9&challenge_md5=35fed0a4d3098563e8a7804ce424218c&user_id=0&edition_id=506:
Invalid user ID

Expected results:
Success

Additional info:
This is the stock, unmodified configuration file, According to the configuration file:

# Enter your user ID and license key below. These are available from
# https://www.maxmind.com/en/my_license_key. If you are only using free
# GeoLite databases, you make leave the 0 values.
UserId 0
LicenseKey 000000000000

This should work, it doesn't.

Comment 1 Paul Howarth 2018-05-09 12:49:50 UTC
I suspect that this is because the free GeoIP libraries have been discontinued by Maxmind. In geoipupdate version 2.5.0, the default configuration references the still-supported GeoIP2 libraries, for use with libmaxminddb.

Could you try this scratch build:
https://koji.fedoraproject.org/koji/taskinfo?taskID=26856461

Comment 2 Roy A. Gilmore 2018-05-09 16:48:50 UTC
(In reply to Paul Howarth from comment #1)
--- 8< --- SNIP --- 8< ---

The scratch build does download and install:

  /usr/share/GeoIP/GeoLite2-Country.mmdb
  /usr/share/GeoIP/GeoLite2-City.mmdb

However, the currently installed GeoIP-1.6.11-3.fc27.x86_64 does not use the new database files (I used "rpm -ev --nodeps GeoIP-GeoLite-data GeoIP-GeoLite-data-extras" to temporarily clear out the old database files). I think all the GeoIP packages (and anything that depends on them) will have to be updated to use the new database files.

Comment 3 Paul Howarth 2018-05-09 17:16:14 UTC
There won't be any further updates to the old database files; you can get the last release by installing the GeoIP-GeoLite-data package.

As for the new database format, that will require applications being ported from GeoIP to libmaxminddb, which doesn't appear to be happening very quickly unfortunately.

Comment 4 Fedora Update System 2018-05-09 17:25:24 UTC
geoipupdate-2.5.0-1.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-d4889c61ba

Comment 5 Philip Prindeville 2018-05-09 17:28:45 UTC
(In reply to Paul Howarth from comment #3)
> There won't be any further updates to the old database files; you can get
> the last release by installing the GeoIP-GeoLite-data package.
> 
> As for the new database format, that will require applications being ported
> from GeoIP to libmaxminddb, which doesn't appear to be happening very
> quickly unfortunately.

How much work would a shim layer (for compatibility) be?

Comment 6 Roy A. Gilmore 2018-05-09 17:58:15 UTC
(In reply to Paul Howarth from comment #3)
> There won't be any further updates to the old database files; you can get
> the last release by installing the GeoIP-GeoLite-data package.

There are more current versions of the v6 database files available for direct download from MaxMind. Maybe the GeoIP-GeoLite-data-extra package should be updated with the latest database files, since geoipupdate can no longer work with the "legacy" database files (at least not without a paid subscription)

> As for the new database format, that will require applications being ported
> from GeoIP to libmaxminddb, which doesn't appear to be happening very
> quickly unfortunately.

OK, yes that is unfortunate

Comment 7 Fedora Update System 2018-05-10 20:00:58 UTC
geoipupdate-2.5.0-1.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-d4889c61ba

Comment 8 Paul Howarth 2018-05-11 10:32:49 UTC
(In reply to Philip Prindeville from comment #5)
> (In reply to Paul Howarth from comment #3)
> > There won't be any further updates to the old database files; you can get
> > the last release by installing the GeoIP-GeoLite-data package.
> > 
> > As for the new database format, that will require applications being ported
> > from GeoIP to libmaxminddb, which doesn't appear to be happening very
> > quickly unfortunately.
> 
> How much work would a shim layer (for compatibility) be?

No idea, but perhaps it would be better (maybe easier) to work on moving upstreams to libmaxminddb, that work then being maintained upstream, than try to fully match the API and ABI of the now-unmaintained GeoIP library?

(In reply to Roy A. Gilmore from comment #6)
> (In reply to Paul Howarth from comment #3)
> > There won't be any further updates to the old database files; you can get
> > the last release by installing the GeoIP-GeoLite-data package.
> 
> There are more current versions of the v6 database files available for
> direct download from MaxMind. Maybe the GeoIP-GeoLite-data-extra package
> should be updated with the latest database files, since geoipupdate can no
> longer work with the "legacy" database files (at least not without a paid
> subscription)

I wonder how many v6 database users there are, and how many would see any noticeable difference from a database that was a few days older? Such differences would likely be swamped by inaccuracies due to the lack of ongoing updates to the databases I think.

Comment 9 Fedora Update System 2018-05-19 21:34:21 UTC
geoipupdate-2.5.0-1.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.