I am using a Rails 4 application, when in production mode i am getting
same IP address for all the members of the same organisation. The
requirement is to get different IP address for each member so as to
uniquely identify each system.
On Saturday, 13 February 2016 05:15:29 UTC-5, Ruby-Forum.com User wrote:
All these fetches me the same IP for each system. How can i uniquely
identify each system? Please help.
remote_ip is calculated from the other two (and a few additional
headers). The calculation may sometimes misunderstand the network
topology,
so if you’re getting an IP that’s part of your infrastructure (load
balancers / proxies / etc) for every client it may be worth looking
into.
Otherwise, your options are very limited. One of the purposes of
organization-level NAT is to avoid leaking internal addresses / machine
identities to the outside (for security). I’ve read of a way to use the
Javascript WebRTC API to get the client’s LAN address, but I wouldn’t
recommend depending on that for anything like licensing or authorization
since any data coming from JS is trivially spoofable.
I’d recommend that you push back on whoever / whatever is imposing this
requirement to figure out what the intent is. You may need to find an
alternative way to achieve that goal.