BPF List
 help / color / mirror / Atom feed
* [PATCH bpf 0/4] lib/buildid: fix a few bugs
@ 2026-12-03 16:31 Chris Mason
  2026-12-03 16:31 ` [PATCH bpf 1/4] lib/buildid: check FMODE_READ before __kernel_read() Chris Mason
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Chris Mason @ 2026-12-03 16:31 UTC (permalink / raw)
  To: bpf, ast, daniel, andrii
  Cc: akpm, eddyz87, memxor, martin.lau, song, yonghong.song, jolsa,
	emil, ihor.solodrai, linux-kernel, mason

Hi everyone,

These are AI generated fixes for a few buildid bugs.

Patches 1-3 add the checks that freader_fetch() needs before it calls
__kernel_read().  Without them, we can trigger a warning, overflow the
kernfs read buffer, or read from a socket.

Patch 4 limits the number of ELF notes we'll walk, so a bad file can't
lock up the CPU.

This is on top of v7.4-rc5.

Chris Mason (4):
  lib/buildid: check FMODE_READ before __kernel_read()
  lib/buildid: check the offset before __kernel_read()
  lib/buildid: check the file type before __kernel_read()
  lib/buildid: limit the number of ELF notes per parse

 lib/buildid.c | 37 +++++++++++++++++++++++++++++++------
 1 file changed, 31 insertions(+), 6 deletions(-)


base-commit: fe6ff8d5d675c01793b9f051d16055dd4aa75244
-- 
2.55.0


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-12-03 18:58 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-12-03 16:31 [PATCH bpf 0/4] lib/buildid: fix a few bugs Chris Mason
2026-12-03 16:31 ` [PATCH bpf 1/4] lib/buildid: check FMODE_READ before __kernel_read() Chris Mason
2026-12-03 16:31 ` [PATCH bpf 2/4] lib/buildid: check the offset " Chris Mason
2026-12-03 16:31 ` [PATCH bpf 3/4] lib/buildid: check the file type " Chris Mason
2026-12-03 18:13   ` sashiko-bot
2026-12-03 18:58     ` Chris Mason
2026-12-03 16:31 ` [PATCH bpf 4/4] lib/buildid: limit the number of ELF notes per parse Chris Mason

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox