[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAEf4BzYf3Q9rbwfG8PbXCHm=QoegP0d8ezYWqwtdNcSORdzhTA@mail.gmail.com>
Date: Fri, 11 Oct 2019 10:56:46 -0700
From: Andrii Nakryiko <andrii.nakryiko@...il.com>
To: Alexei Starovoitov <ast@...nel.org>
Cc: "David S. Miller" <davem@...emloft.net>,
Daniel Borkmann <daniel@...earbox.net>, x86@...nel.org,
Networking <netdev@...r.kernel.org>, bpf <bpf@...r.kernel.org>,
Kernel Team <kernel-team@...com>
Subject: Re: [PATCH v2 bpf-next 03/12] bpf: process in-kernel BTF
On Wed, Oct 9, 2019 at 9:15 PM Alexei Starovoitov <ast@...nel.org> wrote:
>
> If in-kernel BTF exists parse it and prepare 'struct btf *btf_vmlinux'
> for further use by the verifier.
> In-kernel BTF is trusted just like kallsyms and other build artifacts
> embedded into vmlinux.
> Yet run this BTF image through BTF verifier to make sure
> that it is valid and it wasn't mangled during the build.
> If in-kernel BTF is incorrect it means either gcc or pahole or kernel
> are buggy. In such case disallow loading BPF programs.
>
> Signed-off-by: Alexei Starovoitov <ast@...nel.org>
> ---
Acked-by: Andrii Nakryiko <andriin@...com>
> include/linux/bpf_verifier.h | 4 +-
> include/linux/btf.h | 1 +
> kernel/bpf/btf.c | 71 +++++++++++++++++++++++++++++++++++-
> kernel/bpf/verifier.c | 20 ++++++++++
> 4 files changed, 94 insertions(+), 2 deletions(-)
>
[...]
Powered by blists - more mailing lists