]> git.baikalelectronics.ru Git - kernel.git/commit
iwmc3200wifi: add some more range checks
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 18 Oct 2011 06:50:43 +0000 (09:50 +0300)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 8 Nov 2011 20:53:59 +0000 (15:53 -0500)
commit7094377b244952ab27ce7633bf21cac384dcb418
tree66e9d4a71f6b22cc488260f28444fc197d6ff751
parent41dfc59cf0548d1fe9dc5039f3382f111efb1d63
iwmc3200wifi: add some more range checks

My previous patch added a check to get_key() but missed a couple
other places which need range checks.

The problem here is that wifi drivers have different numbers of keys.
The lower levels assume that they can have up to 4 default keys and
2 management keys but this driver only has the default keys so we
could go past the end of the ->keys[] array.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/iwmc3200wifi/cfg80211.c