From: Andrew Lunn <andrew@lunn.ch>
To: The list for a Better Approach To Mobile Ad-hoc Networking
<b.a.t.m.a.n@lists.open-mesh.org>
Cc: Marek Lindner <lindner_marek@yahoo.de>
Subject: Re: [B.A.T.M.A.N.] [PATCH] batctl: add raw wifi packet decapsulation support
Date: Wed, 26 Jan 2011 16:41:27 +0100 [thread overview]
Message-ID: <20110126154127.GA6813@lunn.ch> (raw)
In-Reply-To: <1296052208-6041-1-git-send-email-lindner_marek@yahoo.de>
Hi Marek
> + shost = wifi_hdr->addr2;
> + if (fc & IEEE80211_FCTL_FROMDS)
> + shost = wifi_hdr->addr3;
> + else if (fc & IEEE80211_FCTL_TODS)
> + shost = wifi_hdr->addr4;
> +
> + dhost = wifi_hdr->addr1;
> + if (fc & IEEE80211_FCTL_TODS)
> + dhost = wifi_hdr->addr3;
What would happen if you happened to pick up a WDS packet? Four
addresses in the packet. Do we see sensible addresses?
> +
> + hdr_len = 24;
> + if ((fc & IEEE80211_FCTL_FROMDS) && (fc & IEEE80211_FCTL_TODS))
> + hdr_len = 30;
Again, WDS? We are now a few bytes out when decoding the rest of the
packet.
Andrew
next prev parent reply other threads:[~2011-01-26 15:41 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-26 14:30 [B.A.T.M.A.N.] [PATCH] batctl: add raw wifi packet decapsulation support Marek Lindner
2011-01-26 15:02 ` Sven Eckelmann
2011-01-27 12:37 ` Marek Lindner
2011-01-26 15:41 ` Andrew Lunn [this message]
2011-01-27 12:27 ` Marek Lindner
2011-01-28 17:24 ` Andrew Lunn
2011-01-28 20:14 ` Marek Lindner
2011-01-29 16:16 ` [B.A.T.M.A.N.] [PATCHv2] " Marek Lindner
2011-02-01 22:08 ` Marek Lindner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110126154127.GA6813@lunn.ch \
--to=andrew@lunn.ch \
--cc=b.a.t.m.a.n@lists.open-mesh.org \
--cc=lindner_marek@yahoo.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).