2020-02-05 19:10:43 +00:00
|
|
|
From: Linus Lüssing <ll@simonwunderlich.de>
|
|
|
|
Date: Wed, 5 Feb 2020 20:10:43 +0100
|
|
|
|
Subject: ath10k: increase rx buffer size to 2048
|
|
|
|
|
|
|
|
Before, only frames with a maximum size of 1528 bytes could be
|
|
|
|
transmitted between two 802.11s nodes.
|
|
|
|
|
|
|
|
For batman-adv for instance, which adds its own header to each frame,
|
|
|
|
we typically need an MTU of at least 1532 bytes to be able to transmit
|
|
|
|
without fragmentation.
|
|
|
|
|
|
|
|
This patch now increases the maxmimum frame size from 1528 to 1656
|
|
|
|
bytes.
|
|
|
|
|
|
|
|
Tested with two ath10k devices in 802.11s mode, as well as with
|
|
|
|
batman-adv on top of 802.11s with forwarding disabled.
|
|
|
|
|
|
|
|
Fix originally found and developed by Ben Greear.
|
|
|
|
|
|
|
|
Link: https://github.com/greearb/ath10k-ct/issues/89
|
|
|
|
Link: https://github.com/greearb/ath10k-ct/commit/9e5ab25027e0971fa24ccf93373324c08c4e992d
|
|
|
|
Cc: Ben Greear <greearb@candelatech.com>
|
|
|
|
Signed-off-by: Linus Lüssing <ll@simonwunderlich.de>
|
|
|
|
|
|
|
|
Forwarded: https://patchwork.kernel.org/patch/11367055/
|
|
|
|
|
|
|
|
--- a/drivers/net/wireless/ath/ath10k/htt.h
|
|
|
|
+++ b/drivers/net/wireless/ath/ath10k/htt.h
|
mac80211: backport upstream fixes for FragAttacks
From the patch series description:
Several security issues in the 802.11 implementations were found by
Mathy Vanhoef (New York University Abu Dhabi), who has published all
the details at
https://papers.mathyvanhoef.com/usenix2021.pdf
Specifically, the following CVEs were assigned:
* CVE-2020-24586 - Fragmentation cache not cleared on reconnection
* CVE-2020-24587 - Reassembling fragments encrypted under different
keys
* CVE-2020-24588 - Accepting non-SPP A-MSDU frames, which leads to
payload being parsed as an L2 frame under an
A-MSDU bit toggling attack
* CVE-2020-26139 - Forwarding EAPOL from unauthenticated sender
* CVE-2020-26140 - Accepting plaintext data frames in protected
networks
* CVE-2020-26141 - Not verifying TKIP MIC of fragmented frames
* CVE-2020-26142 - Processing fragmented frames as full frames
* CVE-2020-26143 - Accepting fragmented plaintext frames in
protected networks
* CVE-2020-26144 - Always accepting unencrypted A-MSDU frames that
start with RFC1042 header with EAPOL ethertype
* CVE-2020-26145 - Accepting plaintext broadcast fragments as full
frames
* CVE-2020-26146 - Reassembling encrypted fragments with non-consecutive
packet numbers
* CVE-2020-26147 - Reassembling mixed encrypted/plaintext fragments
In general, the scope of these attacks is that they may allow an
attacker to
* inject L2 frames that they can more or less control (depending on the
vulnerability and attack method) into an otherwise protected network;
* exfiltrate (some) network data under certain conditions, this is
specific to the fragmentation issues.
A subset of these issues is known to apply to the Linux IEEE 802.11
implementation (mac80211). Where it is affected, the attached patches
fix the issues, even if not all of them reference the exact CVE IDs.
In addition, driver and/or firmware updates may be necessary, as well
as potentially more fixes to mac80211, depending on how drivers are
using it.
Specifically, for Intel devices, firmware needs to be updated to the
most recently released versions (which was done without any reference
to the security issues) to address some of the vulnerabilities.
To have a single set of patches, I'm also including patches for the
ath10k and ath11k drivers here.
We currently don't have information about how other drivers are, if
at all, affected.
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-05-12 12:28:37 +00:00
|
|
|
@@ -2243,7 +2243,7 @@ struct htt_rx_chan_info {
|
2020-02-05 19:10:43 +00:00
|
|
|
* Should be: sizeof(struct htt_host_rx_desc) + max rx MSDU size,
|
|
|
|
* rounded up to a cache line size.
|
|
|
|
*/
|
|
|
|
-#define HTT_RX_BUF_SIZE 1920
|
|
|
|
+#define HTT_RX_BUF_SIZE 2048
|
|
|
|
#define HTT_RX_MSDU_SIZE (HTT_RX_BUF_SIZE - (int)sizeof(struct htt_rx_desc))
|
|
|
|
|
|
|
|
/* Refill a bunch of RX buffers for each refill round so that FW/HW can handle
|