Opened 6 years ago

Closed 6 years ago

#8191 closed enhancement (fixed)

Implement probe IP address lookup via geoip.ubuntu.com/lookup

Reported by: hellais Owned by: hellais
Priority: Medium Milestone:
Component: Archived/Ooni Version:
Severity: Keywords:
Cc: BjornArnelid Actual Points:
Parent ID: #7348 Points:
Reviewer: Sponsor:

Description

If we are unable to detect the probes IP address by connecting to Tor (either because Tor has not been started or because we have failed to do a GETINFO Address), we should detect the probes IP address by doing a GET request to http://geoip.ubuntu.com/lookup.

We should probably abstract the logic for detecting the probes geo data in a separate object that is called something like GeoData(). Such object should have a method lookup() and it should be instanced and such method called before any test is started.

Relevant twisted documentation: https://twistedmatrix.com/documents/current/web/howto/client.html (section on Receiving Responses).

For an implementation of an object to unroll the response body look at https://gitweb.torproject.org/ooni-probe.git/blob/HEAD:/ooni/utils/net.py#l63 and it's usage inside of the http test template: https://gitweb.torproject.org/ooni-probe.git/blob/HEAD:/ooni/templates/httpt.py#l227.

Child Tickets

Change History (1)

comment:1 Changed 6 years ago by aagbsn

Resolution: fixed
Status: newclosed

This was implemented and merged in:
https://github.com/TheTorProject/ooni-probe/pull/71

Note: See TracTickets for help on using tickets.