+---- Maksim Yevmenkin wrote:
| > I'm in a bit of a bind.  I want a sequence of ethernet frames to send
| > up through this framework.  Hooking to ng_ether will give me this but I
| > am restricted to taking ALL frames (thus taking the machine offline) or
| > orphaned frames (where I will have to write some sort of traffic
| > generator to make frames of an invalid type).  The third option here is
| > to hack ng_ether to deliver frames out the lower hook as well as up
| > into the kernel IP stack, thus giving me a complete stream without
| > taking the box offline.  I've gotten libnet which seems to fit the bill
| > to generate any orphans I want, but making a stream of frames by hand
| > is a pain.
| 
| why do you need ng_ether, ng_tee etc. at all? can't you just write
| your code with assumption that there will be one (or few) input
| hooks? can't you just connect *user-space* Ethernet/IP frame generator
| to the input hook(s) and send frames? that's what i did in HCI/Bluetooth
| stack when i had no *real* Bluetooth hardware. i just wrote simple
| *user-space* Bluetooth device simulator and connected it to the stack.
| then i run VMWare and debug my code. 
| 
| you can use tcpdump and save dumps to the file and then just read it
| and re-inject them into your node. this way you can test at least
| basic stuff, i.e. frame parsing etc.

Thought of this just after I sent the email - d'oh!

Thanks!

-- 
Steve Tremblett

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-net" in the body of the message

Reply via email to