]> git.baikalelectronics.ru Git - kernel.git/commit
wext: Add bound checks for copy_from_user
authorArjan van de Ven <arjan@linux.intel.com>
Sat, 26 Sep 2009 18:51:14 +0000 (20:51 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 28 Sep 2009 20:55:06 +0000 (16:55 -0400)
commit658256913153ca76eb1191573e8d562177a24f01
tree42da5de2f0ee624e675d7b27f7e8c05301de0d2d
parentae933996265abc2adbc6f3d8d5e34be7615abab6
wext: Add bound checks for copy_from_user

The wireless extensions have a copy_from_user to a local stack
array "essid", but both me and gcc have failed to find where
the bounds for this copy are located in the code.

This patch adds some basic sanity checks for the copy length
to make sure that we don't overflow the stack buffer.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Cc: linux-wireless@vger.kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/wireless/wext.c