• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Routing Information
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Routing Information


  • Subject: Re: Routing Information
  • From: "Pablo Bendersky" <email@hidden>
  • Date: Tue, 13 Jun 2006 08:36:05 -0300

My question is Cocoa related. While I know how to find the default
gateway using the command line, I don't know how to find it using
Cocoa.
I found SystemConfiguration.framework may provide the information, but
can't find samples on how to do it.

Thanks.

On 6/12/06, Chris Suter <email@hidden> wrote:

On 13/06/2006, at 10:13 AM, Pablo Bendersky wrote:

> Hi,
> Is there any way of getting the default gateway's IP address?
> So far, my solution would be to use an NSTask and parse the result of
> running netstat.
> Is there any other alternative?
> Thanks in advance.

This isn't really Cocoa.

Have a look at the route(4) man page. (Haven't tried this myself but
it looks promising.)

I'd have thought you could also find the source for netstat somewhere.







_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Routing Information (From: "Pablo Bendersky" <email@hidden>)
 >Re: Routing Information (From: Chris Suter <email@hidden>)

  • Prev by Date: Re: Freeze Dried Objects/Archiving
  • Next by Date: Array Controller - Making some items uneditable?
  • Previous by thread: Re: Routing Information
  • Next by thread: Problem using my Framework
  • Index(es):
    • Date
    • Thread