Code Monkey home page Code Monkey logo

abeebus's Introduction

Abeebus

Abeebus is a GeoIP lookup utility utilizing ipinfo.io services. This script is very useful for parsing email headers, log files, and any other arbitrary data for IPv4 addresses, and then obtaining GeoIP data for each of those addresses.

Video Demo:

Parse Email Headers and Files for GeoIP Location Data

For any given file(s), Abeebus will:

  • Extract valid IPv4 addresses (e.g., "CSI: Cyber" addresses like 951.27.9.840 will not match)
  • Ignore duplicates
  • Ignore bogon addresses, the loopback network, link local addresses, and RFC 1918 (private) addresses

For each remaining address, Abeebus will provide the following data as available from ipinfo.io:

- IP Address, Hostname, Country, Region, City, Postal Code, Latitude, Longitude, ASN, Count

By default, Abeebus will display the data to stdout in the following format:

IP Address    | Hostname                                  | Country | Region   | City    | Postal Code | Latitude | Longitude | ASN                     | Count
52.73.116.225 | ec2-52-73-116-225.compute-1.amazonaws.com | US      | Virginia | Ashburn | 20149       | 39.0437  | -77.4875  | AS14618 Amazon.com Inc. | 5
  • Using the "-w" option, you can provide a filename to which Abeebus will output the data in CSV format (useful for working with large data sets in Timeline Explorer, Microsoft Excel, or LibreOffice Calc):
IP Address,Hostname,Country,Region,City,Postal Code,Latitude,Longitude,ASN,Count
52.73.116.225,ec2-52-73-116-225.compute-1.amazonaws.com,US,Virginia,Ashburn,20149,39.0437,-77.4875,AS14618 Amazon.com Inc.,5
  • Using the "-a" option, you can provide an ipinfo.io API key if you have large datasets to process.

Abeebus requires Python 3 (no external libraries needed).

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.