]> git.baikalelectronics.ru Git - kernel.git/commit
net: Add explicit bound checks in net/socket.c
authorArjan van de Ven <arjan@linux.intel.com>
Mon, 28 Sep 2009 19:57:44 +0000 (12:57 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 28 Sep 2009 19:57:44 +0000 (12:57 -0700)
commitba2bdc77d688335facde7ec43dd5d39bce192b24
tree178c84b77edbc7cac3223cbe930bd5927a4bf86f
parent133e23e24aa19f1ec3b405d174c853dce582c2e6
net: Add explicit bound checks in net/socket.c

The sys_socketcall() function has a very clever system for the copy
size of its arguments. Unfortunately, gcc cannot deal with this in
terms of proving that the copy_from_user() is then always in bounds.
This is the last (well 9th of this series, but last in the kernel) such
case around.

With this patch, we can turn on code to make having the boundary provably
right for the whole kernel, and detect introduction of new security
accidents of this type early on.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/socket.c