netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] DECnet: don't leak uninitialized stack byte
@ 2010-11-23 21:02 Dan Rosenberg
  2010-11-28 19:32 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Rosenberg @ 2010-11-23 21:02 UTC (permalink / raw)
  To: davem; +Cc: netdev

A single uninitialized padding byte is leaked to userspace.

Signed-off-by: Dan Rosenberg <drosenberg@vsecurity.com>
CC: stable <stable@kernel.org>
---

 net/decnet/af_decnet.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/net/decnet/af_decnet.c b/net/decnet/af_decnet.c
index d6b93d1..cf38f52 100644
--- a/net/decnet/af_decnet.c
+++ b/net/decnet/af_decnet.c
@@ -1556,6 +1556,8 @@ static int __dn_getsockopt(struct socket *sock, int level,int optname, char __us
 			if (r_len > sizeof(struct linkinfo_dn))
 				r_len = sizeof(struct linkinfo_dn);
 
+			memset(&link, 0, sizeof(link));
+
 			switch(sock->state) {
 				case SS_CONNECTING:
 					link.idn_linkstate = LL_CONNECTING;



^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-11-28 19:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-23 21:02 [PATCH] DECnet: don't leak uninitialized stack byte Dan Rosenberg
2010-11-28 19:32 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).