Skip to content

Commit

Permalink
perf_counters: Increase paranoia level
Browse files Browse the repository at this point in the history
Per-cpu counters are an ASLR information leak as they show
the execution other tasks do. Increase the paranoia level
to 1, which disallows per-cpu counters. (they still allow
counting/profiling of own tasks - and admin can profile
everything.)

Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Ingo Molnar committed Aug 28, 2009
1 parent 326ba50 commit 6bb5634
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/perf_counter.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ static atomic_t nr_task_counters __read_mostly;
* 1 - disallow cpu counters to unpriv
* 2 - disallow kernel profiling to unpriv
*/
int sysctl_perf_counter_paranoid __read_mostly;
int sysctl_perf_counter_paranoid __read_mostly = 1;

static inline bool perf_paranoid_cpu(void)
{
Expand Down

0 comments on commit 6bb5634

Please sign in to comment.