From: Eduard Zingerman <eddyz87@gmail.com>
To: Andrii Nakryiko <andrii.nakryiko@gmail.com>
Cc: I Hsin Cheng <richard120310@gmail.com>,
martin.lau@linux.dev, ast@kernel.org, daniel@iogearbox.net,
andrii@kernel.org, song@kernel.org, yonghong.song@linux.dev,
john.fastabend@gmail.com, kpsingh@kernel.org, sdf@fomichev.me,
haoluo@google.com, jolsa@kernel.org, bpf@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] libbpf: Fix integer overflow issue
Date: Tue, 08 Oct 2024 02:48:54 -0700 [thread overview]
Message-ID: <b7c4b77e22bd8005ad5758706ddefe878f949d94.camel@gmail.com> (raw)
In-Reply-To: <CAEf4BzbpxXqNLa02r0=xw-bHzDoO5BELHqX+Ux35Hh7XRNY92w@mail.gmail.com>
On Mon, 2024-10-07 at 20:42 -0700, Andrii Nakryiko wrote:
[...]
> Not sure what Eduard is suggesting here, tbh. But I think if this
> actually can happen that we have a non-loaded BPF program in one of
> those struct_ops slots, then let's add a test demonstrating that.
Given the call chain listed in a previous email I think that such
situation is not possible (modulo obj->gen_loader, which I know
nothing about).
Thus I suggest to add a pr_warn() and return -EINVAL or something like
that here.
> Worst case of what can happen right now is the kernel rejecting
> struct_ops loading due to -22 as a program FD.
>
> pw-bot: cr
[...]
next prev parent reply other threads:[~2024-10-08 9:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-07 16:46 [PATCH] libbpf: Fix integer overflow issue I Hsin Cheng
2024-10-07 17:22 ` Al Viro
2024-10-07 17:36 ` Song Liu
2024-10-07 19:13 ` Eduard Zingerman
2024-10-08 3:42 ` Andrii Nakryiko
2024-10-08 9:48 ` Eduard Zingerman [this message]
2024-10-08 17:21 ` Andrii Nakryiko
2024-10-08 17:34 ` Eduard Zingerman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b7c4b77e22bd8005ad5758706ddefe878f949d94.camel@gmail.com \
--to=eddyz87@gmail.com \
--cc=andrii.nakryiko@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=haoluo@google.com \
--cc=john.fastabend@gmail.com \
--cc=jolsa@kernel.org \
--cc=kpsingh@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.lau@linux.dev \
--cc=richard120310@gmail.com \
--cc=sdf@fomichev.me \
--cc=song@kernel.org \
--cc=yonghong.song@linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox