mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [GIT pull] core fix for 4.11
@ 2017-04-02  7:20 Thomas Gleixner
  0 siblings, 0 replies; only message in thread
From: Thomas Gleixner @ 2017-04-02  7:20 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: LKML, Andrew Morton, Ingo Molnar, H. Peter Anvin

Linus,

please pull the latest core-urgent-for-linus git tree from:

   git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git core-urgent-for-linus

Prevent leaking kernel memory via /proc/$pid/syscall when the queried task
is not in a syscall.

Thanks,

	tglx

------------------>
Kees Cook (1):
      lib/syscall: Clear return values when no stack


 lib/syscall.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/syscall.c b/lib/syscall.c
index 17d5ff5fa6a3..2c6cd1b5c3ea 100644
--- a/lib/syscall.c
+++ b/lib/syscall.c
@@ -12,6 +12,7 @@ static int collect_syscall(struct task_struct *target, long *callno,
 
 	if (!try_get_task_stack(target)) {
 		/* Task has no stack, so the task isn't in a syscall. */
+		*sp = *pc = 0;
 		*callno = -1;
 		return 0;
 	}

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2017-04-02  7:20 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-02  7:20 [GIT pull] core fix for 4.11 Thomas Gleixner

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®