diff options
author | gordon <gordon@FreeBSD.org> | 2018-05-08 17:14:54 +0000 |
---|---|---|
committer | gordon <gordon@FreeBSD.org> | 2018-05-08 17:14:54 +0000 |
commit | 9d2807bdf72c932cabb0bf577328a5ba0eff42af (patch) | |
tree | bc9d33b202825d3a66a1680abad21dc91f53d478 /sys/compat/linux/linux_ioctl.c | |
parent | cbb1d33b29d7f60ebcbec4611e41b37b34fa25a5 (diff) | |
download | FreeBSD-src-9d2807bdf72c932cabb0bf577328a5ba0eff42af.zip FreeBSD-src-9d2807bdf72c932cabb0bf577328a5ba0eff42af.tar.gz |
Fix multiple small kernel memory disclosures. [EN-18:05.mem]
Approved by: so
Security: CVE-2018-6920
Security: CVE-2018-6921
Security: FreeBSD-EN-18:05.mem
Diffstat (limited to 'sys/compat/linux/linux_ioctl.c')
-rw-r--r-- | sys/compat/linux/linux_ioctl.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/compat/linux/linux_ioctl.c b/sys/compat/linux/linux_ioctl.c index b77db6c..5c30c19 100644 --- a/sys/compat/linux/linux_ioctl.c +++ b/sys/compat/linux/linux_ioctl.c @@ -253,6 +253,7 @@ linux_ioctl_hdio(struct thread *td, struct linux_ioctl_args *args) } else if ((args->cmd & 0xffff) == LINUX_HDIO_GET_GEO_BIG) { struct linux_hd_big_geometry hdbg; + memset(&hdbg, 0, sizeof(hdbg)); hdbg.cylinders = fwcylinders; hdbg.heads = fwheads; hdbg.sectors = fwsectors; @@ -2477,6 +2478,7 @@ linux_ioctl_socket(struct thread *td, struct linux_ioctl_args *args) printf("%s(): ioctl %d on %.*s\n", __func__, args->cmd & 0xffff, LINUX_IFNAMSIZ, lifname); #endif + memset(ifname, 0, sizeof(ifname)); ifp = ifname_linux_to_bsd(td, lifname, ifname); if (ifp == NULL) return (EINVAL); |