summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorAndrii Nakryiko <andrii@kernel.org>2023-05-24 15:54:19 -0700
committerAlexei Starovoitov <ast@kernel.org>2023-05-25 10:08:20 -0700
commitc4c84f6fb2c4dc4c0f5fd927b3c3d3fd28b7030e (patch)
tree302fba4fa72060b2ba3e8b4911cf9bcf48eac435 /arch
parentfcf1fa29c8ea75bf104c35ce29b65ce2ba6a6a9d (diff)
bpf: drop unnecessary bpf_capable() check in BPF_MAP_FREEZE command
Seems like that extra bpf_capable() check in BPF_MAP_FREEZE handler was unintentionally left when we switched to a model that all BPF map operations should be allowed regardless of CAP_BPF (or any other capabilities), as long as process got BPF map FD somehow. This patch replaces bpf_capable() check in BPF_MAP_FREEZE handler with writeable access check, given conceptually freezing the map is modifying it: map becomes unmodifiable for subsequent updates. Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/r/20230524225421.1587859-2-andrii@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions