Re: ping driving me nuts!
Re: ping driving me nuts!
- Subject: Re: ping driving me nuts!
- From: Quinn <email@hidden>
- Date: Thu, 24 Jul 2003 10:26:24 +0100
At 23:05 -0700 23/7/03, Duane Murphy wrote:
I think there is a sample code on the apple web site that shows how to do
this. I think it might be able to do it without being privileged.
Yes.
<
http://developer.apple.com/samplecode/Sample_Code/Networking/SimplePing.htm>
The ability to do this is a 10.2 feature.
Before that example, which is restricted to some version of 10.2, you
must be root to open a SOCK_RAW socket. There is a discussion in
Richard's (?) Unix book that talks about how to transfer sockets from one
app to another. This is how you open a privileged socket without the
entire app being priv.
There code that shows this on our web site.
<
http://developer.apple.com/samplecode/Sample_Code/Networking/BSDLLCTest.htm>
This sample incorporates a new version of MoreAuthSample that has
support for descriptor passing.
btw I'll update the official release of MoreAuthSample when I get
time; there's another feature I want to add before I do the new
release.
For our purposes we just exec ping and let it do the work for us.
I'd prefer it if you didn't do that. It requires you to interpret
the results that ping prints, which means you might break if we
change ping's UI.
S+E
--
Quinn "The Eskimo!" <
http://www.apple.com/developer/>
Apple Developer Technical Support * Networking, Communications, Hardware
_______________________________________________
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.