Re: cleanest way to get outside IP address
Re: cleanest way to get outside IP address
- Subject: Re: cleanest way to get outside IP address
- From: Jens Alfke <email@hidden>
- Date: Thu, 8 Jan 2009 13:19:16 -0800
On Jan 8, 2009, at 11:52 AM, Nicolas Berloquin wrote:
I'm looking for the cleanest or prefered way to get the "outside" IP
adress of a host on a network,
from the said host. For example a mac behind a NAT router.
The new-in-10.5 NAT-traversal API in <dns_sd.h> supports this. Search
the header for "portmapping". The restrictions are:
* 10.5 or later
* Router must support UPNP or NAT-PMP (most do).
* Only looks at one NAT, so doesn't support double-NAT situations
(which happen with certain ISPs.)
* The only documentation is some comments in the header file.
I have some code that wraps an Objective-C API around this, but it's
not handy right now; I could dig it up later, if you'd like.
—Jens
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden