lib/buildid: fix a few bugs
Status from this message: This series was applied to bpf/bpf.git (master)
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 All 4 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | lib/buildid: check FMODE_READ before __kernel_read()lib/ | +6 | 0 replies | Applied |
| 2/4 | lib/buildid: check the offset before __kernel_read()lib/ | +6 | 0 replies | Applied |
| 3/4 | lib/buildid: check the file type before __kernel_read()lib/ | +7 | 1 reply | Applied |
| 4/4 | lib/buildid: limit the number of ELF notes per parselib/ | +12 | 0 replies | Applied |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH bpf 0/4] lib/buildid: fix a few bugs
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
Signature · 1 line
2.55.0