diff options
| author | Matt Bobrowski <mattbobrowski@google.com> | 2024-06-25 06:28:57 +0000 |
|---|---|---|
| committer | Alexei Starovoitov <ast@kernel.org> | 2024-06-26 13:17:32 -0700 |
| commit | aa293983d2020390e286544b120f3cd0a3d40749 (patch) | |
| tree | a62f7dab25bae1f0f0ccd09e75b75c85ff97e2e7 /tools/testing/selftests/bpf/progs/setget_sockopt.c | |
| parent | bpf: add missing check_func_arg_reg_off() to prevent out-of-bounds memory acc... (diff) | |
| download | linux-aa293983d2020390e286544b120f3cd0a3d40749.tar.gz linux-aa293983d2020390e286544b120f3cd0a3d40749.zip | |
bpf: add new negative selftests to cover missing check_func_arg_reg_off() and reg->type check
Add new negative selftests which are intended to cover the
out-of-bounds memory access that could be performed on a
CONST_PTR_TO_DYNPTR within functions taking a ARG_PTR_TO_DYNPTR |
MEM_RDONLY as an argument, and acceptance of invalid register types
i.e. PTR_TO_BTF_ID within functions taking a ARG_PTR_TO_DYNPTR |
MEM_RDONLY.
Reported-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Acked-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Acked-by: Eduard Zingerman <eddyz87@gmail.com>
Signed-off-by: Matt Bobrowski <mattbobrowski@google.com>
Link: https://lore.kernel.org/r/20240625062857.92760-2-mattbobrowski@google.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'tools/testing/selftests/bpf/progs/setget_sockopt.c')
0 files changed, 0 insertions, 0 deletions
