Page MenuHomeFreeBSD

imgact_elf: Check note body sizes
ClosedPublic

Authored by markj on Oct 13 2025, 12:41 PM.
Tags
None
Referenced Files
F137775930: D53063.diff
Tue, Nov 25, 5:55 PM
Unknown Object (File)
Sun, Nov 23, 12:43 PM
Unknown Object (File)
Sun, Nov 23, 2:18 AM
Unknown Object (File)
Fri, Nov 21, 1:20 PM
Unknown Object (File)
Fri, Nov 21, 5:12 AM
Unknown Object (File)
Tue, Nov 18, 7:37 AM
Unknown Object (File)
Sun, Nov 16, 5:25 PM
Unknown Object (File)
Mon, Nov 10, 6:46 AM
Subscribers

Details

Summary

In parse_notes we validate that the note name fits within the note
buffer, but we do not do the same for the note data, so there is some
potential for an OOB read in the note handler. Add a bounds check.

Reported by: Ilja Van Sprundel <ivansprundel@ioactive.com>

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 67767
Build 64650: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Oct 13 2025, 2:37 PM
kib added inline comments.
sys/kern/imgact_elf.c
2834
2841–2842
markj marked 2 inline comments as done.
  • Fix an unrelated typo
  • Perform a single check
This revision now requires review to proceed.Oct 14 2025, 1:46 PM
This revision is now accepted and ready to land.Oct 14 2025, 2:07 PM
This revision was automatically updated to reflect the committed changes.