Ip geolocation how does it work




















Check out the Geolocation Software article on wikipedia for some interesting links on the topic. There's in the internet infrastructure something called an Autonomous System, defintion here.

Each provider has been assigned at least one of these. These are assigned to providers, which off course have a location, so the routing protocols know by the ASN what zone they're in. For a quick start into geolocation, open a command line and enter tracert stackoverflow. Mostly, the first few lines already give away important hints about your location. Basically they guess based on the IP address.

If you want somtjhing that's cheap and mostly works and aren't worried about alienating your users it;s a good solution. Stack Overflow for Teams — Collaborate and share knowledge with a private group. Create a free Team What is Teams? Collectives on Stack Overflow. Learn more. How does IP geolocating work? Ask Question. Asked 11 years, 10 months ago. Active 6 years, 3 months ago. Viewed 28k times. I'm not looking for a service that does this.

I'm just curious as to how geolocation works. Improve this question. With all of these challenges in mind, however, IP-based geolocation can still deliver accurate location data. There are many IP geolocation database providers.

While each database provider gets their IP address information from ARIN or a different regional Internet Registry , the assignment regularly changes, as some database providers release unwanted IP addresses and others obtain new blocks of IP addresses. Along with this, there are different ways to get the data. Most providers offer both free and paid plans, and two different ways to access the data — by downloading the database or by using an API.

As mentioned, most geolocation database providers offer both free and paid plans. The main benefit of the free option is, quite obviously, its cost. That said, these services are usually less accurate than their paid counterparts. The free services may be appropriate if you are cost-conscious or if you are building a minimal viable product of your service.

By contrast, the paid IP geolocation databases provide more accurate data and often provide dedicated support. Also, some of these paid IP geolocation databases can be quite expensive, so you will want to review potential costs before proceeding. Along with the free versus paid difference, IP geolocation database providers usually offer two different ways to access the data.

You can either download the database itself or access it through an application programming interface. The first option is downloading the database and hosting it on your server. You can submit as many requests as you want per day to your database, which can be especially helpful if your application requires many queries per day.

Nevertheless, there are some downsides to downloading the database. A downloaded IP geolocation database may not have as updated of a database as compared to an API database. This means that you may not have as accurate of data compared to accessing your data through an API. In addition, you may face some more technical challenges in downloading and setting up your database. One of the most significant benefits of accessing your data through an API is that the database is constantly updated.

In addition, the onus is on the third-party provider to ensure that the data is available to your application. This allows you to focus on your product rather than on building and maintaining the database.

There are some downsides, however. API databases may also contain some downtime, which may be inconvenient when you need the data. API databases, while they contain more updated information, may also limit the number of requests that you can make per day. You will ultimately want to do your own due diligence, taking into account the advantages and disadvantages of each service. You will also want to account for the prices among the paid alternatives to see which service is most cost-effective for you.

Each provider has different pricing methods and packages. In this context, the IP address acts in a similar way to a postal address used to deliver conventional mail. However, unlike the postal address, an IP address does not have an intrinsic location and does not expose any geographical properties.

This is why you cannot determine the location of a device by its IP address alone. IP Geolocation is an essential technology that overcomes this limitation to help organisations identify the location of their customers based on their IP addresses. This IP Geolocation service is also crucial for preventing online fraud, managing digital rights, and serving targeted marketing material and pricing. Most of these providers declare superior accuracy, although show little transparency on the methodology, and present scarce evidence to support their claimed accuracy.

In general, validation of the accuracy of an IP Geolocation service is challenging and requires a large pool of ground-truth data i. In reality, such data is generally not available, in which case any claimed IP Geolocation accuracy without full transparency is questionable. The IPv4 protocol uses bit addresses which makes the maximum theoretical address space limited to 4,,, 2 32 IP addresses. IPv6, the next-generation protocol, utilises bit addresses which makes the pool considerably larger, but still limited.

Due to the global uniqueness requirement of IP Addresses across both protocols, the global IP address space allocation is heavily regulated. All registries both regional and local allocate their remaining available address space to organisations seeking to utilise it on the public internet. Business entities or autonomous networks that are assigned IP address space for their own use are called Autonomous Systems AS.

Virtually, any organisation seeking to use their own IP addresses on the internet qualifies as an AS. It is a common occurrence that AS entities liberally use their allocated IP space in any manner they wish, and more importantly, in any geographical location they like. Despite existing regulations, there is no way to restrict allocated IP address space geographically.

Therefore, the only ultimately accurate IP Geolocation data is that which is made available by AS operators, who are the only ones who confidently know how and where their IP addresses are utilised. AS, however, are not obliged to share their internal data with any other entity, except for law enforcement agencies within the determined jurisdiction boundaries.

Considering there is more than 80, registered ASs, of which more than 60, are active at any one time active ASNs ranked list , it is largely impractical to form commercial relationships with all.

Receiving the data from a small number of local ISPs may improve regional geolocation accuracy to a minor extent but is not sufficient on a global scale. So, where are they getting their geolocation data from?

WhoIs is by far the most common source of geolocation data. This information discloses all IP addresses registered for each entity they belong to, including independent organisations or ISPs. This data is usually updated on a daily basis and include a set of registration data. This registration data contains the IP address block records and which organisations they are registered under.

It may additionally contain a street address or the network location coordinates, although none of the geographical properties is mandatory. Furthermore, these records are maintained by the registered party and are not validated by any external body. This means the accuracy of the data is questionable even when it is made available.

There are around 10 million records in the global WhoIs database for IPv4 alone, some of which can serve a very accurate IP Geolocation source. For example, a small internet Cafe with a static IP address or small range of addresses used on-premises and recorded into the RIR database inclusive of its physical address.

This scenario exposes accurate geolocation information with a precision up to a street address. In most cases, when an organisation reports incorrect or outdated information, or outsources the registered address blocks to another party, the records will not reveal the IP usage location. This is a standardised exterior gateway protocol to exchange routing information amongst active Autonomous Systems AS on the internet.

BGP involves the announcement of preferred pathways and direction of internet address blocks prefixes. This announcement eventually propagates across all other peers worldwide to inform them on how to send traffic to that IP address range if required.

In a nutshell, this is how global internet connectivity works. Now, how this can be helpful for IP Geolocation? Firstly, unlike the WhoIs data which shows the organisation registered against a particular IP address block, BGP data can reveal who is actually using it. This is not always the same enterprise entity as we discussed above.

Secondly, the BGP data can also reveal what addresses are not used at all, an unannounced space, with which a geolocation process should not even be attempted. The IP address is not a physical object in a physical location. It is simply a numerical label that can be allocated and unallocated from individual devices or networks. There is no way we can geolocate a label that is not in use allocated. Some other usages of BGP data rely on the assumption that IP addresses belonging to certain prefixes are meant to share geographical proximity.

This, however, does not always hold true. Prefixes tend to aggregate along the way and may include a cluster of several smaller prefixes that originate from different regions. There are many additional data sources that can be utilised for IP geolocation which qualify as field evidence data. The best example is the data received directly from users or submitted using GPS-enabled devices, such as mobile phones or tablets.

This data can reveal the alleged geographical coordinates of a device using a public IP address and can serve as empirical evidence or ground-truth data for that particular IP address at that particular moment in time.



0コメント

  • 1000 / 1000