• 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: Sample code for sending raw packets?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sample code for sending raw packets?


  • Subject: Re: Sample code for sending raw packets?
  • From: "Justin C. Walker" <email@hidden>
  • Date: Fri, 13 Oct 2006 17:57:30 -0700


On Oct 13, 2006, at 14:53 , Dave Camp wrote:
On Oct 13, 2006, at 2:30 PM, Justin C. Walker wrote:
On Oct 13, 2006, at 11:37 , Dave Camp wrote:
On Oct 13, 2006, at 11:26 AM, Justin C. Walker wrote:
[snip]
If I understand the recipe above, you have the MAC address/IP address association already in the ARP cache, by dint of step 1. If this is true, the system will handle the frame assembly and transmission.

If you need to send the "whole frame" by yourself, step 1 seems superfluous.

My original intent was to avoid step 1 by sending the whole frame myself. However, folks here think that step 1 isn't as bad as I thought it was, so I'm going to try that. The downside is that I get to use the command line as an API and hope it works well. :-)

Yeah; I re-read your post and noticed I missed that detail.

The other responders are correct: this is not only not a "bad thing", it's actually the right way to do it. In fact, as has been suggested a couple of times, you are probably better off using the commands supplied by the system than hacking your own code anyway: this is a low-duty-cycle operation, so performance isn't an issue; and using the system's commands means that you are generally in sync with changes.

There is a minor concern with changing usage, but these commands may be stable enough that that is not an issue.

Justin

--
Justin C. Walker, Curmudgeon-At-Large
Director
Institute for the Enhancement of the Director's Income
--------
"Weaseling out of things is what separates us from the animals.
 Well, except the weasel."
      - Homer J Simpson
--------


_______________________________________________ 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
References: 
 >Sample code for sending raw packets? (From: Dave Camp <email@hidden>)
 >Re: Sample code for sending raw packets? (From: "Justin C. Walker" <email@hidden>)
 >Re: Sample code for sending raw packets? (From: Dave Camp <email@hidden>)
 >Re: Sample code for sending raw packets? (From: "Justin C. Walker" <email@hidden>)
 >Re: Sample code for sending raw packets? (From: Dave Camp <email@hidden>)

  • Prev by Date: Re: Sample code for sending raw packets?
  • Next by Date: how to enumerate TCP and UDP listeners
  • Previous by thread: Re: Sample code for sending raw packets?
  • Next by thread: Re: Sample code for sending raw packets?
  • Index(es):
    • Date
    • Thread