Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Which IP address should I be using for a socket?

843789Mar 30 2009 — edited Mar 31 2009
I'm trying to create a socket to connect to my IP address. The problem is that I have an "outside" IP address and an "inside" IP address.

According to http://whatismyipaddress.com/, my IP address is 97.100.76.196. But aside from that, my wireless internet router assigns different devices in my home different IP addresses. For example, on my computer, it is 10.0.0.9. So when I create a Socket, what would my parameters be since I essentially have 2 different IP addresses?
new Socket("which IP address???", int port);
Thanks so much!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 28 2009
Added on Mar 30 2009
38 comments
731 views