Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpf: exempt CAP_BPF from checks against bpf_jit_limit #1817

Closed
wants to merge 2 commits into from

Commits on Sep 22, 2021

  1. adding ci files

    Nobody committed Sep 22, 2021
    Configuration menu
    Copy the full SHA
    6c8d619 View commit details
    Browse the repository at this point in the history
  2. bpf: exempt CAP_BPF from checks against bpf_jit_limit

    When introducing CAP_BPF, bpf_jit_charge_modmem was not changed to
    treat programs with CAP_BPF as privileged for the purpose of JIT
    memory allocation. This means that a program without CAP_BPF can
    block a program with CAP_BPF from loading a program.
    
    Fix this by checking bpf_capable in bpf_jit_charge_modmem.
    
    Fixes: 2c78ee8 ("bpf: Implement CAP_BPF")
    Signed-off-by: Lorenz Bauer <lmb@cloudflare.com>
    lmb authored and Nobody committed Sep 22, 2021
    Configuration menu
    Copy the full SHA
    48ee422 View commit details
    Browse the repository at this point in the history