FW: Raw Sockets
Thu May 8 19:47:23 PDT 2003
On Thu, May 08, 2003 at 03:46:53PM -0500, Dave Hinkle wrote:
> Ok, I've written a little program to simplify as much as possible the code
> that doesn't work. The example program opens up a raw socket and sends an
> Ethernet packet (type 1535) every second.
Do you have any special reason for using exactly ether proto 1535? If
you replace that with 1536, I would bet that the problem goes away.. ;-)
There are different encapsulation methods for IEEE 802.11 frames and
Host AP driver selects which one to use based on the ethertype. If this
type is 1535 or smaller, it is assumed to be length field, not protocol.
As such, there will be no additional encapsulation and the "protocol" is
replaced by the real length of the frame in the receiving system. In
this case, your test packet changes to one with type 10, not 1535..
I could change Host AP driver to encapsulate all frames with 0..1535 in
protocol field with the same RFC1042 header like most other frames. That
would probably make the packets look the same in the receiver. However,
before doing this, I would like to confirm that this would be the
correct way to send such a frame (and that the frame you are trying
to send is actually valid).
Jouni Malinen PGP id EFC895FA
More information about the Hostap