mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Kangjie Lu <kangjielu@gmail.com>
To: catalin.marinas@arm.com
Cc: will.deacon@arm.com, james.morse@arm.com,
	linux-kernel@vger.kernel.org, Kangjie Lu <kjlu@gatech.edu>
Subject: [PATCH] fix infoleak in mm
Date: Tue,  3 May 2016 16:36:08 -0400	[thread overview]
Message-ID: <1462307768-5929-1-git-send-email-kjlu@gatech.edu> (raw)

The stack object “si” has a total size of 128; however, only 20
bytes are initialized. The remaining uninitialized bytes are sent
to userland via send_signal

Signed-off-by: Kangjie Lu <kjlu@gatech.edu>
---
 arch/arm64/mm/fault.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm64/mm/fault.c b/arch/arm64/mm/fault.c
index 95df28b..f790eda 100644
--- a/arch/arm64/mm/fault.c
+++ b/arch/arm64/mm/fault.c
@@ -117,6 +117,7 @@ static void __do_user_fault(struct task_struct *tsk, unsigned long addr,
 {
 	struct siginfo si;
 
+	memset(&si, 0, sizeof(si));
 	if (unhandled_signal(tsk, sig) && show_unhandled_signals_ratelimited()) {
 		pr_info("%s[%d]: unhandled %s (%d) at 0x%08lx, esr 0x%03x\n",
 			tsk->comm, task_pid_nr(tsk), fault_name(esr), sig,
-- 
1.9.1

             reply	other threads:[~2016-05-03 20:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-03 20:36 Kangjie Lu [this message]
2016-05-04 10:31 ` Catalin Marinas

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=1462307768-5929-1-git-send-email-kjlu@gatech.edu \
    --to=kangjielu@gmail.com \
    --cc=catalin.marinas@arm.com \
    --cc=james.morse@arm.com \
    --cc=kjlu@gatech.edu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=will.deacon@arm.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

all inboxes | Powered by JetHome®