Michel Melo says that his client will have "a machine with a server". In this case, it means that, for example, has a WAMP or a MAMP on the machine.
Using this server, locally the client will put data, using client software (for example Firefox)
Exemple:
Main site with Linux is a web server
Local website with WAMP
Client using Firefox on WAMP
Michel’s problem does not seem to be "How will my Linux server know the IP address of Firefox from Usario", because your Linux won’t connect to Linux.
Michel’s problem is "How can my Linux server know the IP of the WAMP server that will connect".
And that?
If so, the answer cannot be "Use JS" because WAMP will not use JS.
The other problem is that if the client’s internet connection is disturbed, your local network may receive another IP address. And in this case, the client’s "server" will not be recognized by the "global server"".
Analyzing this, I think the best option is to transmit on the served site a connection code. And each time this local server will connect to the "global" server, it will transmit the code. IP does not seem to me a reliable or sufficient option.
I think I missed something. Rtcpeerconnection is a solution for browsers, isn’t it? But you say the application has to be installed? What kind of technology/installation do you really have? Because if it were a desktop program installation, it would be very easy to get the real IP from the machine.
– utluiz
hello I think I explained wrong, in the client will have a machine with a server, that will authenticate with the site. the idea is to do something like Chromecast, so I call on a site that is ready for Chromecast it shows an icon
– Michel Melo
I can’t help you with your javascript solution, but just contextualize it: it doesn’t exist or I don’t understand what "internal IP" might be. Generally a computer can have no or multiple network interfaces with an IP configured on each one. For example: you can have three interfaces: wlan, ethernet and loopback. So you can have three recognizable and usable IP addresses (however for different routes/purposes). What do you mean by "Internal IP"?
– user568459
ex: the chormecast, can know what is its IP(internal ip: 192.168.2.110 ; its external ip: 88.888.8.88), ok? if I have Chromecast installed in my network, when I enter a site that is compatible with it, automatically appears an icon that I can see the content of the site in my Chromecast. my idea is to do something similar. ex: is this site (http://net.ipcalf.com/) it shows your internal ip, the ip of your machine
– Michel Melo
Got it. Well, I think it makes no sense for you to talk about "internal IP" and "external IP" because in many cases they will be the same. Conceptually IP is IP. As for javascript, as I said, I can’t help. But I particularly doubt that the discovery of Chromecast on the network is made by a javascript in the browser that scans the network interfaces every time you enter a site enabled for this.
– user568459
OK Francisco thanks I will research more on the subject.
– Michel Melo