From: Dan Carpenter <dan.carpenter@oracle.com>
To: David Airlie <airlied@linux.ie>
Cc: Thomas Hellstrom <thellstrom@vmware.com>,
kernel-janitors@vger.kernel.org,
Vasiliy Kulikov <segooon@gmail.com>,
dri-devel@lists.freedesktop.org,
Jerome Glisse <jglisse@redhat.com>,
Dave Airlie <airlied@redhat.com>
Subject: [patch] vmwgfx: information leak in vmw_execbuf_copy_fence_user()
Date: Tue, 18 Oct 2011 06:10:12 +0000 [thread overview]
Message-ID: <20111018061012.GE27732@elgon.mountain> (raw)
If ret is non-zero then we don't initialize the struct which leaks
stack information to user space.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c b/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c
index d4a1d8b..28e1c35 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c
@@ -1070,6 +1070,8 @@ vmw_execbuf_copy_fence_user(struct vmw_private *dev_priv,
if (user_fence_rep = NULL)
return;
+ memset(&fence_rep, 0, sizeof(fence_rep));
+
fence_rep.error = ret;
if (ret = 0) {
BUG_ON(fence = NULL);
next reply other threads:[~2011-10-18 6:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-18 6:10 Dan Carpenter [this message]
2011-10-18 6:38 ` [patch] vmwgfx: information leak in vmw_execbuf_copy_fence_user() Thomas Hellstrom
2011-10-18 9:30 ` [patch] vmwgfx: information leak in Vasiliy Kulikov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20111018061012.GE27732@elgon.mountain \
--to=dan.carpenter@oracle.com \
--cc=airlied@linux.ie \
--cc=airlied@redhat.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=jglisse@redhat.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=segooon@gmail.com \
--cc=thellstrom@vmware.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox