Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bpf: Reject writes for PTR_TO_MAP_KEY in check_helper_mem_access
commit 7b3552d upstream. It is not permitted to write to PTR_TO_MAP_KEY, but the current code in check_helper_mem_access would allow for it, reject this case as well, as helpers taking ARG_PTR_TO_UNINIT_MEM also take PTR_TO_MAP_KEY. Fixes: 69c087b ("bpf: Add bpf_for_each_map_elem() helper") Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com> Link: https://lore.kernel.org/r/20220319080827.73251-4-memxor@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
- linux-5.18.10-mpi
- linux-5.18.11-mpi
- linux-5.18.12-mpi
- linux-5.18.13-mpi
- linux-5.18.14-mpi
- linux-5.18.15-mpi
- linux-5.18.16-mpi
- linux-5.18.17-mpi
- linux-5.18.18-mpi
- linux-5.18.19-mpi
- linux-5.18.2-mpi
- linux-5.18.3-mpi
- linux-5.18.4-mpi
- linux-5.18.5-mpi
- linux-5.18.6-mpi
- linux-5.18.7-mpi
- linux-5.18.8-mpi
- linux-5.18.9-mpi