wifi: mac80211_hwsim: drop short frames
authorJohannes Berg <johannes.berg@intel.com>
Tue, 15 Aug 2023 19:28:01 +0000 (21:28 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 22 Aug 2023 19:40:39 +0000 (21:40 +0200)
commitfba360a047d5eeeb9d4b7c3a9b1c8308980ce9a6
tree49364a307714c86a7c33cc9f85cf058f2d6497a6
parent67dfa589aa8806c7959cbca2f4613b8d41c75a06
wifi: mac80211_hwsim: drop short frames

While technically some control frames like ACK are shorter and
end after Address 1, such frames shouldn't be forwarded through
wmediumd or similar userspace, so require the full 3-address
header to avoid accessing invalid memory if shorter frames are
passed in.

Reported-by: syzbot+b2645b5bf1512b81fa22@syzkaller.appspotmail.com
Reviewed-by: Jeff Johnson <quic_jjohnson@quicinc.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/virtual/mac80211_hwsim.c