]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net/rds: Fix info leak in rds6_inc_info_copy()
authorKa-Cheong Poon <ka-cheong.poon@oracle.com>
Mon, 26 Aug 2019 09:39:12 +0000 (02:39 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 10 Sep 2019 09:35:10 +0000 (10:35 +0100)
commita4c88340b3ea8caefa1b5d3422bd9925c74b566e
tree35b76c95768d6fea74a9666e9af4033d84a9b66e
parentfdd2bc365fc6ea577db40f7f6566e6f3cdea0181
net/rds: Fix info leak in rds6_inc_info_copy()

[ Upstream commit 7d0a06586b2686ba80c4a2da5f91cb10ffbea736 ]

The rds6_inc_info_copy() function has a couple struct members which
are leaking stack information.  The ->tos field should hold actual
information and the ->flags field needs to be zeroed out.

Fixes: 3eb450367d08 ("rds: add type of service(tos) infrastructure")
Fixes: b7ff8b1036f0 ("rds: Extend RDS API for IPv6 support")
Reported-by: 黄ID蝴蝶 <butterflyhuangxx@gmail.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Ka-Cheong Poon <ka-cheong.poon@oracle.com>
Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/rds/recv.c