[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-talk] GEOIP's



On 05/09/14 19:00, Mike Fikuart wrote:
> Hi Group,
> 
> I am looking into the various files used by the OR’s and OP’s and
> would like to know more about the GEOIP file and use.  I have already
> seen in the
> dir-spec<https://gitweb.torproject.org/torspec.git/blob/HEAD:/dir-spec.txt#l1522>
> document that these GEOIP’s are created in the “Extra-info” document
> and relate to country codes for bridges and in turn was referred to
> the
> blocking.pdf<https://svn.torproject.org/svn/projects/design-paper/blocking.pdf>
> document, which went a bit further in the same vein.
> 
> The blocking.pdf (Design of a blocking-resistant anonymity system,
> Tor Project technical report, Nov 2006) suggests "the compressed
> GEOIP database is only a few hundred kilobytes”, but the geoip file
> on my relay is about 2MB.  Is this just because it is decompressed,
> now a much larger DB or is not the DB being referred to in the
> document?
> 
> The geoip file has 82,363 different Country Code entries listed.
> What do they relate to, as this would far exceed the bridges and
> relays?
> 
> I seem to remember (but now cannot find the reference) that the
> geoip’s have been responsible for improving the routing of data or
> selection of relays for circuits.  Is this correct and how does this
> work?
> 
> I would appreciate an explanation or a point in the direction of the
> appropriate documentation, thanks.

The geoip file is used by clients that wish to include/exclude relays by
country to know where relays are located.  It's also used by relays to
report aggregate statistics on usage by country.

You can find the current geoip file here:

https://gitweb.torproject.org/tor.git/blob/HEAD:/src/config/geoip

The first few lines tell you how this file is generated:

# Last updated based on August 7 2014 Maxmind GeoLite2 Country
# wget
https://geolite.maxmind.com/download/geoip/database/GeoLite2-Country.mmdb.gz
# gunzip GeoLite2-Country.mmdb.gz
# python mmdb-convert.py GeoLite2-Country.mmdb

See also the MaxMind website for details what's contained in their database.

Regarding database size, here's what happens when I compress the geoip file:

-rw-r--r--  1 karsten  staff   2.2M Sep  5 21:18 geoip
-rw-r--r--  1 karsten  staff   678K Sep  5 21:18 geoip.bz2
-rw-r--r--  1 karsten  staff   688K Sep  5 21:18 geoip.gz
-rw-r--r--  1 karsten  staff   402K Sep  5 21:18 geoip.xz

Not sure if this answers all your questions, but maybe it's a start.

All the best,
Karsten
-- 
tor-talk mailing list - tor-talk@xxxxxxxxxxxxxxxxxxxx
To unsubscribe or change other settings go to
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-talk