diff options
author | Christoph Hellwig <hch@lst.de> | 2020-06-08 21:34:40 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-06-09 09:39:15 -0700 |
commit | 8d92db5c04d10381f4db70ed99b1b576f5db18a7 (patch) | |
tree | 51334cc23b1f21ace2bb70f43eb604d86ad19ce7 /kernel/kexec_file.c | |
parent | 19c8d8ac63d39578483db0b82107c172d8edfb07 (diff) | |
download | linux-8d92db5c04d10381f4db70ed99b1b576f5db18a7.tar.bz2 |
bpf: rework the compat kernel probe handling
Instead of using the dangerous probe_kernel_read and strncpy_from_unsafe
helpers, rework the compat probes to check if an address is a kernel or
userspace one, and then use the low-level kernel or user probe helper
shared by the proper kernel and user probe helpers. This slightly
changes behavior as the compat probe on a user address doesn't check
the lockdown flags, just as the pure user probes do.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Cc: Alexei Starovoitov <ast@kernel.org>
Cc: Daniel Borkmann <daniel@iogearbox.net>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/20200521152301.2587579-14-hch@lst.de
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/kexec_file.c')
0 files changed, 0 insertions, 0 deletions