Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.
Hi all, please see this major site announcement: https://www.boards.ie/discussion/2058427594/boards-ie-2026

whois and country ID from IP Address

  • 13-08-2009 03:01PM
    #1
    Registered Users, Registered Users 2 Posts: 136 ✭✭


    I have a list of IP addresess and I want to be able to determine the 2 letter country code from it via command line on Unix/Linux. Is it possible to use whois and just get back the country code only ? Or is there another command line tool ?
    Thanks a mill


Comments

  • Registered Users, Registered Users 2 Posts: 2,163 ✭✭✭hobochris


    I dont think theres a tool yet(I could be wrong), but what your looking for is called GeoTargeting or more specifically Ip spidering.

    Here's a we based tool if its any use to you:

    http://whatismyipaddress.com/?gclid=CPvIosLnoJwCFZ4A4wodsXh-eA

    Im sure you could right a script to check the above url from command line.


  • Closed Accounts Posts: 1,567 ✭✭✭Martyr


    try GeoIP library, it probably has some test apps you could tweak for your purpose.


  • Registered Users, Registered Users 2 Posts: 136 ✭✭pleuraXeraphim


    Great Thanks a lot for your suggestions.

    Regards Dave


  • Registered Users, Registered Users 2 Posts: 136 ✭✭pleuraXeraphim


    Brilliant

    After a lot of messing about to get it to compile etc etc.
    It works great. Thanks again.


Advertisement
Advertisement