Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Finding a device id through which TCP packet is sent




On May 30, 2007, at 07:28 , parag vibhute wrote:

Hi all,

This is my first mail & I have following objectives to do.
1. Suppose there are more that one network connections (like one through
ethernet card & other through airport) are present from mac. Now I have made
TCP connection using BSD socket API. I want to get device id (stuff like
that) of network device through which my TCP packet is getting sent (or u
can say my TCP communication is going on). I will use this device id as
mentioned in following step.
2. Now when any connection status changes ( say network cable gets
disconnected), I want to get notification of that. Also want to know device
id whose network status is changed.
3. Then I will compare this device id ( whose network status is changed)
with the device id ( through which my TCP communication was going on). If
match is found then I will inform user otherwise I will just ignore it.

The SystemConfiguration framework does just what you want: it will provide notification when there is a change in the network infrastructure (like network devices being attached or detached; devices going on- or off-line; and network addresses being modified). Check the developer docs and Apple's developer website for more information.


Justin

--
Justin C. Walker, Curmudgeon-At-Large
Institute for the Enhancement of the Director's Income
--------
When LuteFisk is outlawed,
Only outlaws will have LuteFisk
--------



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/macnetworkprog/email@hidden

This email sent to email@hidden
References: 
 >Finding a device id through which TCP packet is sent (From: "parag vibhute" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.