From: Michael Buesch <mb@bu3sch.de>
To: Alejandro Grijalba <sud@latinsud.com>
Cc: linux-wireless@vger.kernel.org, linville@tuxdriver.com
Subject: Re: [PATCH] mac80211: do not alter injected seq numbers
Date: Tue, 8 Apr 2008 10:25:39 +0200 [thread overview]
Message-ID: <200804081025.39645.mb@bu3sch.de> (raw)
In-Reply-To: <47FAB829.9010304@latinsud.com>
On Tuesday 08 April 2008 02:11:21 Alejandro Grijalba wrote:
> When injecting frames we should allow user to play with fields like
> fragment or sequence numbers. This patch prevents mac80211 from modifying
> those fields on injected frames.
>
> Tested on 2.6.24.4 with aireplay-ng.
>
> Signed-off-by: Alejandro Grijalba <sud@latinsud.com>
> ---
> There is still a problem with some drivers (b43) that also modify seq numbers,
> and i cannot find there a clean way to tell whether the frame was injected.
> An alternative way would be to create a radiotap flag meaning not to modify header.
>
> --- linux-2.6.24.4/net/mac80211/tx.c 2008-01-24 23:58:37.000000000 +0100
> +++ linux-2.6.24.4-sud/net/mac80211/tx.c 2008-04-05 16:43:19.000000000 +0200
> @@ -281,6 +281,9 @@ ieee80211_tx_h_sequence(struct ieee80211
> {
> struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)tx->skb->data;
>
> + if (unlikely(tx->flags & IEEE80211_TXRXD_TX_INJECTED))
> + return TXRX_CONTINUE;
> +
> if (ieee80211_get_hdrlen(le16_to_cpu(hdr->frame_control)) >= 24)
> ieee80211_include_sequence(tx->sdata, hdr);
>
This does not work, since we use injection for other types of frames. For example
management frames from hostapd. We don't want (and can't) make hostapd keep track of
sequence numbers.
You'll have to contact radiotap people and add a flag for this. This would also
solve the hardware counter problem then.
--
Greetings Michael.
next prev parent reply other threads:[~2008-04-08 8:26 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-08 0:11 [PATCH] mac80211: do not alter injected seq numbers Alejandro Grijalba
2008-04-08 8:25 ` Michael Buesch [this message]
2008-04-09 8:00 ` Johannes Berg
2008-05-22 17:48 ` JMF
[not found] ` <69e28c910805221115g6290e5e9nef4444efca07aea@mail.gmail.com>
2008-05-22 18:21 ` Stefanik Gábor
2008-05-22 18:34 ` Johannes Berg
2008-05-22 18:52 ` Stefanik Gábor
2008-05-22 19:03 ` Johannes Berg
2008-05-22 19:08 ` Michael Buesch
2008-05-22 19:03 ` Michael Buesch
2008-05-22 19:09 ` JMF
2008-05-22 19:15 ` Johannes Berg
2008-05-22 19:19 ` Tomas Winkler
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=200804081025.39645.mb@bu3sch.de \
--to=mb@bu3sch.de \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=sud@latinsud.com \
/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).