Repository navigation
[rocjitsu] Harden code object parsing - #13704
Merged
Merged
Conversation
kuhar
requested review from
Groverkss and
newling
and
a balanced review from Copilot
October 18, 2026 18:27
❌ PR Check — Action Required
📖 Need help? See the Policy FAQ for details on every check and how to fix failures. |
|
🚫 Please fix the failed policies before requesting reviews. The following policy checks failed:
The |
atgutier
reviewed
Oct 19, 2026
atgutier
left a comment
Contributor
There was a problem hiding this comment.
One agent comment inline
kuhar
force-pushed
the
users/jakub/rocjitsu-code-object-loader-fixes
branch
from
October 19, 2026 23:34
4e1085a to
cb2cc03
Compare
atgutier
reviewed
Oct 20, 2026
atgutier
left a comment
Contributor
There was a problem hiding this comment.
Another major agent finding.
Malformed ELF and HIP bundle metadata can overflow table arithmetic, trigger unaligned reads or drive allocations and copies from unchecked offsets. Program-header loads and kernel descriptor entry calculations also trust wrapped addresses. Read ELF records through bounds-checked copies and require the fixed table strides supported by code-object rewriting. Validate section, symbol, program-header and bundle extents before allocation; retain validated load segments and descriptor offsets across moves; and use checked arithmetic for kernel entry addresses and load ranges. Reject invalid objects before DBI and keep bundle payloads inside their owning section. This retires the old reference-scoped tolerance for malformed unreferenced symbol tables: rewriting can visit every symbol table, so all must use the supported record size. Relocation tables affecting loaded code/data follow the same rule; explicit nonallocated relocation targets retain their established ignore policy. Cover malformed and unsupported tables, wrapped descriptor and load ranges, bundle payload escapes, move construction, and standalone device ELF loading.
kuhar
force-pushed
the
users/jakub/rocjitsu-code-object-loader-fixes
branch
from
October 21, 2026 00:34
cb2cc03 to
9891d8e
Compare
Groverkss
approved these changes
Oct 21, 2026
Contributor
TheRock Submodule Bump ActivityNewest first
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Malformed ELF and HIP bundle metadata can overflow table arithmetic, trigger unaligned reads or drive allocations and copies from unchecked offsets. Program-header loads and kernel descriptor entry calculations also trust wrapped addresses.
Read ELF records through bounds-checked copies that honor entry strides. Validate section, symbol, program-header and bundle tables before allocation; retain validated load segments; and use checked signed arithmetic for kernel entry addresses.
Cover null storage, truncated and strided tables, impossible bundle counts, wrapped descriptor entries and standalone device ELF loading.