diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2013-04-21 14:07:53 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-04-22 10:25:46 -0700 |
commit | 2516ffac94e389cfeeb3abf2fd59d7c688a38f0c (patch) | |
tree | 9262d43af230ae78ff2ee7c34ca0c552bd528cd6 /drivers/staging | |
parent | eecb262922209d714cc24a1dc8e5bf9a9fdbfc65 (diff) |
staging/ozwpan: info leak in oz_cdev_ioctl()
If we're not maxed out then oz_get_pd_list() leaves part of the "list"
struct uninitialized. We should clear this so that no stack information
is leaked to userspace.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/ozwpan/ozcdev.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/ozwpan/ozcdev.c b/drivers/staging/ozwpan/ozcdev.c index ba15aeb7067..27d06666c81 100644 --- a/drivers/staging/ozwpan/ozcdev.c +++ b/drivers/staging/ozwpan/ozcdev.c @@ -253,6 +253,7 @@ static long oz_cdev_ioctl(struct file *filp, unsigned int cmd, case OZ_IOCTL_GET_PD_LIST: { struct oz_pd_list list; oz_trace("OZ_IOCTL_GET_PD_LIST\n"); + memset(&list, 0, sizeof(list)); list.count = oz_get_pd_list(list.addr, OZ_MAX_PDS); if (copy_to_user((void __user *)arg, &list, sizeof(list))) |