[Click] Help!! Madwifi Monitor Mode vs Ad-Hoc Mode... Annotations?
g91d5350 at campus.ru.ac.za
g91d5350 at campus.ru.ac.za
Thu Sep 3 05:08:50 EDT 2009
Hello again, Clickers
I need some assistance...
The click script below creates a "station" device and does very little
with it. When I run this script on two nodes in Ad-Hoc mode, it works
fine. When I run it in Madwifi's Monitor mode, it doesn't work...
FromHost(station, 192.168.1.2/24) // use a different IP for each node!
-> Print("FromHost")
-> Queue
-> to_dev :: ToDevice (ath0);
FromDevice(ath0, PROMISC true)
// 802.11 headers configured in MadWifi, so there's no need for PrismDecap etc
-> Print("FromDevice")
//-> CheckIPHeader(14)
//-> GetIPAddress(16)
-> ToHost(station);
Before anybody jumps on me, I know that I'm doing dubious things here.
I know that under Ad-hoc mode the wireless driver will convert my
Ethernet frames into 802.11 frames. Under Monitor mode, I am
transmitting raw Ethernet frames - which is what I want for this
experiment. I know too that I should filter incoming packets to
differentiate between my data and other traffic (such as spurious
beacons and 802.11 traffic)... I'll get there...
I use PING to test whether I can communicate over the "station"
device. Pings work fine in ad-hoc mode, but in monitor mode they
don't. My packets appear to arrive at the recipient OK - I print them
after FromDevice(). But it seems like Linux loses the packets after
that.
I have a suspicion that Linux might be silently dropping my packets
because they are not correctly annotated. On a whim, I tried adding a
GetIPAddress(16) - but that didn't help.
Am I missing something? I spent until 1-o-clock this morning trying
to figure this stuff out. Any help would be greatly appreciated!
Thanks!
- Kevin
More information about the click
mailing list