Skip to content

jhfoo/whatismyip

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

whatismyip

Purpose

tl;dr: Network routing analyzer by showing the IP a host sees coming from a specific network.

Long answer: Sometimes Ping is not good enough; traceroute sometimes works but not Ping. Why? Because they work slightly differently. In my case, my network between 2 hosts located in different geolocations route through a few potential (as in they should be disabled) NAT config, and it's important to confirm which NAT is seen by the receiving host.

Installation

This is now a Python app. Installation involves creating a virtual environment so dependencies can be installed in the user space.

%git clone https://github.com/jhfoo/whatismyip.git
%cd whatismyip
%./bin/setup

Running

This spins up a simple HTTP REST service listening on all addresses.

%./bin/dev

To see what the receiving host sees simply go a HTTP GET on port 8001

curl <remote host>:8001
# sample response
# {"RemoteIp":"192.168.130.8"}

Tested config

  • FreeBSD w/ Python 3.11

About

Simple app to log the ip of the requestor

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published