OSDN Git Service

mac80211: Reject malformed SSID elements
authorWill Deacon <will@kernel.org>
Fri, 4 Oct 2019 09:51:31 +0000 (10:51 +0100)
committerJohannes Berg <johannes.berg@intel.com>
Fri, 4 Oct 2019 12:01:14 +0000 (14:01 +0200)
commit4152561f5da3fca92af7179dd538ea89e248f9d0
treeee65bdc3d24161e21a99abf6da6a19b8b40955bb
parent313c3fe9c2348e7147eca38bb446f295b45403a0
mac80211: Reject malformed SSID elements

Although this shouldn't occur in practice, it's a good idea to bounds
check the length field of the SSID element prior to using it for things
like allocations or memcpy operations.

Cc: <stable@vger.kernel.org>
Cc: Kees Cook <keescook@chromium.org>
Reported-by: Nicolas Waisman <nico@semmle.com>
Signed-off-by: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20191004095132.15777-1-will@kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/mlme.c