Correct way to obtain the 802.11 headers with a raw socket?
hvelayos at imit.kth.se
Thu Nov 21 10:02:28 EST 2002
Thank you for your answer.
I was trying to write a small program to measure the handover time as my
laptop moves from one AP to another. This is why I needed the ctrl/mgmt
frames as well. Unfortunately, I don't have the time to modify the code in
the way you indicated, so I will use two cards in the same laptop (one
working in managed mode and the other in monitor mode).
Nevertheless, I am using HostAP as the client and it works very well. You
are doing a superb work. I wish it would be integrated in the kernel soon.
> -----Original Message-----
> From: hostap-admin at shmoo.com [mailto:hostap-admin at shmoo.com]On Behalf Of
> Jouni Malinen
> Sent: den 19 november 2002 06:13
> To: hostap at shmoo.com
> Subject: Re: Correct way to obtain the 802.11 headers with a raw socket?
> On Sun, Nov 17, 2002 at 02:07:17AM +0100, Hector Velayos wrote:
> > which is the way to obtain the 802.11 headers using a raw socket in a
> > station?
> If you are talking about using Host AP driver as the client and wanting
> to get 802.11 headers, the way would be to start modifying the source
> code.. ;-)
> > I know that activating the monitor mode (level 2) it is possible and
> > actually I did. But the station cannot communicate with the AP while in
> > monitor mode 2 :/ and I would need the station to remain working.
> Which frames do you need? If it is enough to get all data frames (and
> not ctrl/mgmt frames), it could be sufficent to setup Prism2 card in
> promiscuous mode and modify RX code path of the driver to pass 802.11
> headers to the kernel. You would also need to make sure that TX path
> would handle this correctly.
> I'm redesigning the RX code path at the moment and with the new code it
> should be easier to do this kind of changes. However, you might also
> need some support from the kernel netstack, since changing the netdev to
> use 802.11 headers would indicate that the TX frames should be with
> 802.11 headers when they are sent to the driver.
> Jouni Malinen PGP id EFC895FA
> HostAP mailing list
> HostAP at shmoo.com
More information about the HostAP