[PATCH] net/appletalk: Fix kernel memory disclosure

2017-01-09 Thread Vlad Tsyrklevich
ipddp_route structs contain alignment padding so kernel heap memory is leaked when they are copied to user space in ipddp_ioctl(SIOCFINDIPDDPRT). Change kmalloc() to kzalloc() to clear that memory. Signed-off-by: Vlad Tsyrklevich <v...@tsyrklevich.net> --- drivers/net/appletalk/ipddp.c | 2

Re: [PATCH] ethtool: Zero memory allocated for statistics

2016-10-15 Thread Vlad Tsyrklevich
for some NICs. Deeper bugs are undoubtedly laying around. On Sat, Oct 15, 2016 at 5:11 PM, Vlad Tsyrklevich <v...@tsyrklevich.net> wrote: > I agree that we should propagate those errors and I'll prepare a new change > to do so for phy_driver.get_stats(), ethtool_o

[PATCH] ethtool: Zero memory allocated for statistics

2016-10-14 Thread Vlad Tsyrklevich
(), mv88e6xxx_get_ethtool_stats(), bnx2x_self_test(), be_self_test(), etc. Signed-off-by: Vlad Tsyrklevich <v...@tsyrklevich.net> --- net/core/ethtool.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/net/core/ethtool.c b/net/core/ethtool.c index 9774898..7202915 100644 ---

[PATCH] drivers/ptp: Fix kernel memory disclosure

2016-10-11 Thread Vlad Tsyrklevich
The reserved field precise_offset->rsv is not cleared before being copied to user space, leaking kernel stack memory. Clear the struct before it's copied. Signed-off-by: Vlad Tsyrklevich <v...@tsyrklevich.net> --- drivers/ptp/ptp_chardev.c | 1 + 1 file changed, 1 insertion(+) d