angler-fishThe Vulnerability History Project

bpf: Implement CAP_BPF

      Implement permissions as stated in uapi/linux/capability.h
In order to do that the verifier allow_ptr_leaks flag is split
into four flags and they are set as:
  env->allow_ptr_leaks = bpf_allow_ptr_leaks();
  env->bypass_spec_v1 = bpf_bypass_spec_v1();
  env->bypass_spec_v4 = bpf_bypass_spec_v4();
  env->bpf_capable = bpf_capable();

The first three currently equivalent to perfmon_capable(), since leaking kernel
pointers and reading kernel memory via side channel attacks is roughly
equivalent to reading kernel memory with cap_perfmon.

'bpf_capable' enables bounded loops, precision tracking, bpf to bpf calls and
other verifier features. 'allow_ptr_leaks' enable ptr leaks, ptr conversions,
subtraction of pointers. 'bypass_spec_v1' disables speculative analysis in the
verifier, run time mitigations in bpf array, and enables indirect variable
access in bpf programs. 'bypass_spec_v4' disables emission of sanitation code
by the verifier.

That means that the networkin
    
commit 2c78ee898d8f10ae6fb2fa23a3fbaec96b1b7366
+1 -1
+17 -1
+3
+5 -5
+1 -1
+1 -1
+1 -1
+2 -2
+3 -1
+1 -1
+1 -1
+1 -1
+1 -1
+1 -1
+68 -21
+20 -17
+3
+2 -2
+2 -2
expand_less