summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/perf/callchain_64.c
diff options
context:
space:
mode:
authorRafael Aquini <aquini@redhat.com>2020-06-08 06:40:51 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2020-06-08 20:05:56 +0200
commite77132e75845470065768e2205727e6be52cb7f4 (patch)
treedd222e1900ff7b29db7f001e1a4fcb353a9935cc /arch/powerpc/perf/callchain_64.c
parentpanic: add sysctl to dump all CPUs backtraces on oops event (diff)
downloadlinux-e77132e75845470065768e2205727e6be52cb7f4.tar.xz
linux-e77132e75845470065768e2205727e6be52cb7f4.zip
kernel/sysctl.c: ignore out-of-range taint bits introduced via kernel.tainted
Users with SYS_ADMIN capability can add arbitrary taint flags to the running kernel by writing to /proc/sys/kernel/tainted or issuing the command 'sysctl -w kernel.tainted=...'. This interface, however, is open for any integer value and this might cause an invalid set of flags being committed to the tainted_mask bitset. This patch introduces a simple way for proc_taint() to ignore any eventual invalid bit coming from the user input before committing those bits to the kernel tainted_mask. Signed-off-by: Rafael Aquini <aquini@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Reviewed-by: Luis Chamberlain <mcgrof@kernel.org> Cc: Kees Cook <keescook@chromium.org> Cc: Iurii Zaikin <yzaikin@google.com> Cc: "Theodore Ts'o" <tytso@mit.edu> Link: http://lkml.kernel.org/r/20200512223946.888020-1-aquini@redhat.com Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/powerpc/perf/callchain_64.c')
0 files changed, 0 insertions, 0 deletions