summaryrefslogtreecommitdiffstats
path: root/fs/proc
diff options
context:
space:
mode:
authorKonstantin Khlebnikov <khlebnikov@openvz.org>2011-03-23 16:42:48 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2011-03-23 19:46:36 -0700
commit51e031496d50f87ff519a63cfd4fc2f415f03336 (patch)
tree75c177b8aeba82fffb80960eed1c77bb4188c362 /fs/proc
parent523fb486bfd94e3a3b16a42bcb21b1959cf14df8 (diff)
downloadlinux-51e031496d50f87ff519a63cfd4fc2f415f03336.tar.gz
linux-51e031496d50f87ff519a63cfd4fc2f415f03336.tar.bz2
linux-51e031496d50f87ff519a63cfd4fc2f415f03336.zip
proc: hide kernel addresses via %pK in /proc/<pid>/stack
This file is readable for the task owner. Hide kernel addresses from unprivileged users, leave them function names and offsets. Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org> Acked-by: Kees Cook <kees.cook@canonical.com> Cc: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/proc')
-rw-r--r--fs/proc/base.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c
index d49c4b5d2c3e..c3af15e9c070 100644
--- a/fs/proc/base.c
+++ b/fs/proc/base.c
@@ -340,7 +340,7 @@ static int proc_pid_stack(struct seq_file *m, struct pid_namespace *ns,
save_stack_trace_tsk(task, &trace);
for (i = 0; i < trace.nr_entries; i++) {
- seq_printf(m, "[<%p>] %pS\n",
+ seq_printf(m, "[<%pK>] %pS\n",
(void *)entries[i], (void *)entries[i]);
}
kfree(entries);