MMMMS
MMMMS

Reputation: 2201

how to detect main server ip address from client system using java?

Is it possible to get main server system's(which is connected to LAN) ip address from client system using java?

If yes, how can i do using code?

Upvotes: 0

Views: 256

Answers (1)

AlexR
AlexR

Reputation: 115388

Generally it is impossible whether using java or any other programming language. This is the reason that LANs exist. The internal IP address is not sent outside the local network and therefore cannot be detected.

However if client and server are developed especially to complete this task to can send the IP on application level. For example to send the IP as a HTTP header if connection is done over HTTP.

Upvotes: 1

Related Questions