summaryrefslogtreecommitdiff
path: root/lib/mpi/mpi-inline.c
diff options
context:
space:
mode:
authorPeilin Ye <yepeilin.cs@gmail.com>2020-08-20 17:30:52 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-08-27 10:31:47 +0300
commit22f2be57784e95210a2b4e732fac586f1c08abbe (patch)
tree43672b43406a41484a5af1810ab6e3349b3afa97 /lib/mpi/mpi-inline.c
parentdf805b956877bc1741467c4164c3f75d2e76982d (diff)
downloadlinux-22f2be57784e95210a2b4e732fac586f1c08abbe.tar.xz
net/smc: Prevent kernel-infoleak in __smc_diag_dump()
[ Upstream commit ce51f63e63c52a4e1eee4dd040fb0ba0af3b43ab ] __smc_diag_dump() is potentially copying uninitialized kernel stack memory into socket buffers, since the compiler may leave a 4-byte hole near the beginning of `struct smcd_diag_dmbinfo`. Fix it by initializing `dinfo` with memset(). Fixes: 4b1b7d3b30a6 ("net/smc: add SMC-D diag support") Suggested-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Peilin Ye <yepeilin.cs@gmail.com> Signed-off-by: Ursula Braun <ubraun@linux.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/mpi/mpi-inline.c')
0 files changed, 0 insertions, 0 deletions