Re: SCNetworkCheckReachabilityByName && proxies
Re: SCNetworkCheckReachabilityByName && proxies
- Subject: Re: SCNetworkCheckReachabilityByName && proxies
- From: Allan Nathanson <email@hidden>
- Date: Wed, 18 Jun 2003 15:46:52 -0400
On Wednesday, June 18, 2003, at 3:37 PM, Glen Simmons wrote:
On Wednesday, June 18, 2003, at 02:24 PM, Allan Nathanson wrote:
On Wednesday, June 18, 2003, at 2:55 PM, Glen Simmons wrote:
I'm trying to determine if it's safe to make an internet connection
by using SCNetworkCheckReachabilityByName, but it's not working. I'm
guessing that the problem is that I'm behind a firewall and connect
through a proxy. I've searched high and low, but haven't found any
mention of using SCNetworkCheckReachabilityByName behind firewalls.
What's the scoop?
Simply put, SCNetworkCheckReachabilityByName knows nothing about
proxy servers. The "name" you are passing as an argument will be
evaluated via a name->lookup query (aka gethostbyname,
getipnodebyname, getaddrinfo) and the returned flags will be based on
the reachability of the addresses returned by the query.
... besides, I have no idea that the provided "name" needs to go
through a web proxy, a ftp proxy, a ... proxy, ...
OK, I can see that. What, then, would be the proper procedure for this
situation?
You (or your application) knows the context of the connection that will
need to be established. Given the context you check if any proxy
servers have been configured. If a proxy server should be used the
check the reachability of the proxy, else check the target host.
... or maybe a better question would be to ask which APIs you are going
to use to establish a connection to the target host?
- Allan
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.