Fix non-root ownership of package files#6788
Open
harkgill-amd wants to merge 2 commits into
Open
Conversation
…ocal privilege escalation
… already-installed systems on upgrade
✅ All Checks Passed — Ready for Review
📖 Need help? See the Policy FAQ for details on every check and how to fix failures. |
|
🎉 All checks passed! This PR is ready for review. |
nunnikri
requested changes
Jul 22, 2026
nunnikri
left a comment
Contributor
There was a problem hiding this comment.
Fix may not help. As the package promotion and signing is not done using this.
@yanyao-wang can we take these fixes in the promotion jobs?
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.
Motivation
Addresses ROCm/ROCm#6496
Technical Details
Ownership for 7.14 packaged directories points to
rocm-signer/rocm-signeror uid1004instead of root. This allows for non-root users who have uid == 1004 to overwrite files in the install tree. This is a regression from the mainline ROCm 6/7 releases where all files and directories were own byroot:root.--root-owner-group/%defattr(-, root, root, -)force0/0(root ownership) regardless of builder identity, fakeroot presence, or how staging owns files.do_fix_ownership()introduces post-inst mechanism to update existing installsTest Plan
Test Result
Reproduction + fix
/opt/rocm/core/bin/amd-smi= 1004/1005/opt/rocm/core/bin/amd-smi= rootpostinst ownership repair (dpkg -i / rpm -i as root):
Submission Checklist