nl80211: fix HT capability attribute validation
authorJohannes Berg <johannes.berg@intel.com>
Thu, 3 Nov 2011 08:27:01 +0000 (09:27 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 7 Nov 2011 18:19:13 +0000 (13:19 -0500)
commit6c7394197af90f6a332180e33f5d025d3037d883
tree9fcebadff9c028206a9c51fe99764662e4acacbf
parent3432f9233704a66e6067944339a311744243707d
nl80211: fix HT capability attribute validation

Since the NL80211_ATTR_HT_CAPABILITY attribute is
used as a struct, it needs a minimum, not maximum
length. Enforce that properly. Not doing so could
potentially lead to reading after the buffer.

Cc: stable@vger.kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/wireless/nl80211.c