
Géolocaliser n'importe quelle adresse IP en un emplacement physique en utilisant la latence
Un outil simple qui utilise Globalping pour résoudre une IP en un emplacement physique basé sur la latence.
Apprenez-en plus sur cet outil et pourquoi il existe dans notre blog :
We have ipinfo at home or how to geolocate IPs in your CLI using latency
git clone https://github.com/jimaek/geolocation-tool
cd geolocation-tool
npm install && npm link
geolocate
docker run \
-e GLOBALPING_TOKEN=<optional_token> \
--name geolocation-tool \
--rm \
$(docker build -q .) \
-- <IP_ADDRESS> [OPTIONS]
Il est recommandé d'exécuter l'outil avec un jeton pour bénéficier d'une limite plus élevée de 500 tests par heure.
Cet outil lira le jeton depuis la variable d'environnement GLOBALPING_TOKEN. C'est la même variable utilisée par le CLI Globalping.
Obtenez un jeton gratuit dans le Tableau de bord Globalping.
Resolve an IP. A default limit of 50 probes is set per phase.
USA has 4 phases. All other countries have 3 phases.
This means the total usage is going to be Phases * Limit.
So by default 200 for USA and 150 for the rest.
+30 for continent selection in phase 1.
geolocate 213.133.116.45
-L/--limit sets a higher limit of probes per phase.
This will improve accuracy, especially for cities but will consume lots of credits
geolocate 213.133.116.45 -L 200
Provide token explicitly
GLOBALPING_TOKEN=XXX geolocate 213.133.116.45
# geolocate 45.95.160.61
Geolocating 45.95.160.61...
Phase 1: Detecting continent...
Europe: 123.12 ms
Oceania: 172.49 ms
North America: 57.23 ms
South America: 93.96 ms
Asia: 167.03 ms
Africa: 257.46 ms
Best continent: North America (57.23 ms)
Phase 2: Detecting country...
Measuring from 50 probes...
[████████████████████████████████████████] 100.0% 50/50 - Best: US (0.01 ms)
United States: 0.01ms
Canada: 42.96ms
Best country: United States (0.01ms)
Phase 3: Detecting US state...
Measuring from 50 probes...
[████████████████████████████████████████] 100.0% 50/50 - Best: FL (0.26 ms)
Florida: 0.26ms
Illinois: 0.38ms
Oklahoma: 0.81ms
Best state: Florida (0.26ms)
Phase 4: Detecting city...
Measuring from 37 probes...
[███████████████████████████████████████░] 97.3% 36/37 - Best: Miami (0.01 ms)
Top 3 Locations:
─────────────────────────────────────────────────
1. Miami, Florida, USA 0.01 ms
2. West Palm Beach, Florida, USA 5.38 ms
3. Tampa, Florida, USA 5.80 ms
═══════════════════════════════════════════════════
SUMMARY
═══════════════════════════════════════════════════
Location: Miami, Florida, United States
Minimum Latency: 0.01 ms
Confidence: Very High
═══════════════════════════════════════════════════