Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-76532

http://www.geoplugin.net doesnt work, breaking iplookup_find_location()

XMLWordPrintable

    • MOODLE_401_STABLE

      In function iplookup_find_location() we have:
      $ipdata = download_file_content('http://www.geoplugin.net/json.gp?ip='.$ip);

      See https://github.com/moodle/moodle/blob/MOODLE_401_STABLE/iplookup/lib.php#L76 .

      If this line triggers, it will cause Moodle to try to connect to currently non-functional http://www.geoplugin.net . Curl will time out after 20 seconds, so loading the page for end-user will take over 20 seconds.

      I would suggest removing this external call & dependency from iplookup_find_location() altogether. The DB file ($CFG->geoip2file) should be downloaded & configured by Moodle admin and used here if available.

            Unassigned Unassigned
            tmuras Tomasz Muras
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.