summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorKevin McKinney <klmckinney1@gmail.com>2011-12-17 11:53:37 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2011-12-22 13:32:45 -0800
commit221fd753dd002222b595f8af0e289fff0c9cf5a8 (patch)
tree3b785d0fa39cd89a3d31867064c565f24321df8c /lib
parentb72a7c859efc9e0cf13600b30a555457a08dd86f (diff)
Staging: bcm: Fix an invalid dereference to a kmalloc in IOCTL_BCM_BULK_WRM
Variable IoBuffer.InputLength is chosen from userspace, and can therefore be less than the intended size. In this case,the memory from the kmalloc call is eventually cast to a PBULKWRM_BUFFER. If the IoBuffer.InputLength does not meet the minimum size of PBULKWRM_BUFFER, then we will get a kernel Oops. To resolve this issue, this patch verifies IoBuffer.InputLength meets the minimum size before invoking the kmalloc call. Signed-off-by: Kevin McKinney <klmckinney1@gmail.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'lib')
0 files changed, 0 insertions, 0 deletions