GithubHelp home page GithubHelp logo

homer6 / geoipd Goto Github PK

View Code? Open in Web Editor NEW
5.0 3.0 0.0 726 KB

A linux daemon (and client) that provides quick lookups (3 microseconds) for geoip queries at the city level. MIT license.

C++ 100.00%

geoipd's Introduction

Overview

This is a geoip client and server that runs under linux. And while this code is under the MIT license, the data files required by this program require a license from Maxmind.com.

Please visit their website to obtain the city-level geoip CSVs.

Dependencies

Installation

  • git clone git://github.com/homer6/geoipd.git
  • cd geoipd
  • cmake .
  • make

Usage

Starting the server (the server will only listen locally): ./geoipd --locations-file=GeoIPCity-134-Location.csv --blocks-file=GeoIPCity-134-Blocks.csv

Running the client, once the server is running: ./geoip --host=localhost --ip-address=206.87.31.18 {"city":"Kelowna","region":"BC","country":"CA","latitude":"49.9000","longitude":"-119.4833","area_code":"","metro_code":"","postal_code":""}

Possible Results

Normal Result (only country is guaranteed): {"city":"Kelowna","region":"BC","country":"CA","latitude":"49.9000","longitude":"-119.4833","area_code":"","metro_code":"","postal_code":""}

No result found: {}

Error (if the server is down): {"error":"Connection Refused"}

geoipd's People

Contributors

homer6 avatar e2 avatar

Stargazers

Ahmet Soğuksu avatar  avatar  avatar Rafal Zajac avatar Mariano Casal avatar

Watchers

Mariano Casal avatar  avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.