diff options
author | Daniel Borkmann <daniel@iogearbox.net> | 2018-11-02 11:35:46 +0100 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2018-11-02 21:51:15 +0100 |
commit | 28c2fae726bf5003cd209b0d5910a642af98316f (patch) | |
tree | ea8c71b2ba991e29419116d933efb9022457f331 /kernel/futex_compat.c | |
parent | Merge branch 'bpf-accurate-prog-addr' (diff) | |
download | linux-28c2fae726bf5003cd209b0d5910a642af98316f.tar.xz linux-28c2fae726bf5003cd209b0d5910a642af98316f.zip |
bpf: fix bpf_prog_get_info_by_fd to return 0 func_lens for unpriv
While dbecd7388476 ("bpf: get kernel symbol addresses via syscall")
zeroed info.nr_jited_ksyms in bpf_prog_get_info_by_fd() for queries
from unprivileged users, commit 815581c11cc2 ("bpf: get JITed image
lengths of functions via syscall") forgot about doing so and therefore
returns the #elems of the user set up buffer which is incorrect. It
also needs to indicate a info.nr_jited_func_lens of zero.
Fixes: 815581c11cc2 ("bpf: get JITed image lengths of functions via syscall")
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Cc: Sandipan Das <sandipan@linux.vnet.ibm.com>
Cc: Song Liu <songliubraving@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'kernel/futex_compat.c')
0 files changed, 0 insertions, 0 deletions