[patch 69/71] econet: Fix econet_getname() leak

From: Greg KH
Date: Fri Sep 04 2009 - 20:22:05 EST


2.6.30-stable review patch. If anyone has any objections, please let us know.

------------------
From: Eric Dumazet <eric.dumazet@xxxxxxxxx>

commit 80922bbb12a105f858a8f0abb879cb4302d0ecaa upstream.

econet_getname() can leak kernel memory to user.

Signed-off-by: Eric Dumazet <eric.dumazet@xxxxxxxxx>
Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxx>

---
net/econet/af_econet.c | 1 +
1 file changed, 1 insertion(+)

--- a/net/econet/af_econet.c
+++ b/net/econet/af_econet.c
@@ -520,6 +520,7 @@ static int econet_getname(struct socket
if (peer)
return -EOPNOTSUPP;

+ memset(sec, 0, sizeof(*sec));
mutex_lock(&econet_mutex);

sk = sock->sk;


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/