diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2009-08-06 03:34:06 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-08-06 13:08:38 -0700 |
commit | 17ac2e9c58b69a1e25460a568eae1b0dc0188c25 (patch) | |
tree | 99e38906c8e9e4d53aa03aa73a3d34e2d9ebd4df | |
parent | b4adbb4ddf63091f48668e7ff1b9b0f6f84d4b40 (diff) | |
download | linux-3.10-17ac2e9c58b69a1e25460a568eae1b0dc0188c25.tar.gz linux-3.10-17ac2e9c58b69a1e25460a568eae1b0dc0188c25.tar.bz2 linux-3.10-17ac2e9c58b69a1e25460a568eae1b0dc0188c25.zip |
rose: Fix rose_getname() leak
rose_getname() can leak kernel memory to user.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/rose/af_rose.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/rose/af_rose.c b/net/rose/af_rose.c index f0a76f6bca7..e5f478ca3d6 100644 --- a/net/rose/af_rose.c +++ b/net/rose/af_rose.c @@ -954,6 +954,7 @@ static int rose_getname(struct socket *sock, struct sockaddr *uaddr, struct rose_sock *rose = rose_sk(sk); int n; + memset(srose, 0, sizeof(*srose)); if (peer != 0) { if (sk->sk_state != TCP_ESTABLISHED) return -ENOTCONN; |