Skip to content

wifi: zero-pad SDIO writes to avoid leaking heap data

Tristan Madani brcm80211 linux-wireless lkml stable 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2wifi: brcmfmac: zero-pad SDIO write to 4-byte boundarydrivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c+3 -01 reply
2/2wifi: rsi: zero-pad SDIO TX to block boundarydrivers/net/wireless/rsi/rsi_91x_sdio.c+3 -00 replies

Reviews trailers per patch

1 of 2 patches has a Reviewed-by or Acked-by.

PatchArend van Spriel
1/2A-b
2/2

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH wireless 0/2] wifi: zero-pad SDIO writes to avoid leaking heap data

From: Tristan Madani <[email protected]>

Several wireless drivers round up the length passed to sdio_memcpy_toio() / sdio_writesb() for alignment purposes but do not clear the padding bytes. The SDIO controller then reads past the original buffer into adjacent heap memory, sending stale kernel data to the wireless device.

Fix brcmfmac (4-byte alignment) and rsi (block alignment) by zero-filling the gap before the write.

A third patch for rtw88 hits the same class of bug but needs a rebase and will follow separately.

Tristan Madani (2):
wifi: brcmfmac: zero-pad SDIO write to 4-byte boundary
wifi: rsi: zero-pad SDIO TX to block boundary

 drivers/net/wireless/broadcom/brcm80211/brcmfmac/bcmsdh.c | 3 +++
 drivers/net/wireless/rsi/rsi_91x_sdio.c                   | 3 +++
 2 files changed, 6 insertions(+)
Signature · 1 line
2.47.3