fix(register): attribute public ssh publishes to user#64
Merged
TrevorBasinger merged 2 commits intomainfrom Apr 17, 2026
Merged
fix(register): attribute public ssh publishes to user#64TrevorBasinger merged 2 commits intomainfrom
TrevorBasinger merged 2 commits intomainfrom
Conversation
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.
Summary
Make
roar register --public ...use the authenticated SSH user identity for canonical lineage attribution instead of falling back toanonymous.With this change, when SSH auth is valid and
--publicis used:Problem
Previously,
roar register --public ...could succeed over SSH auth, but Roar often computed the public lineage as if it were created by:creator_identity = "anonymous"That meant:
What changed
Public publish auth resolution
When
--publicis used and no bearer login is available, Roar now:GET /api/v1/auth/meusing SSH signature authcreator_identityfrom that authenticated userPublic scope behavior
--publicnow consistently takes the public path and ignores repo binding for scope selection.This keeps the existing intended behavior:
--public=> public--public=> private+attributed pathDry-run parity
register --dry-run --public ...now resolves the same authenticated SSH identity path, so preview hashes match real registration behavior.Behavior after this change
roar register --public ...Tests added
Unit
Integration
Added product-path tests proving that:
--publicignores an existing repo bindingLive e2e
Added a live GLaaS test:
test_register_public_with_valid_ssh_attributes_session_to_authenticated_userThis verifies end-to-end that public SSH registration shows the authenticated user on the public session route.
Verification
Ran:
pytest tests/unit/test_publish_creator_identity.py tests/unit/test_publish_auth_context.py tests/integration/test_public_publish_intent_cli.py✅pytest -m "not live_glaas and not ebpf"✅ruff check .✅mypy roar✅Live validation:
pytest tests/live_glaas/test_register_live.py -k attributes_session_to_authenticated_user -m live_glaas --dist noRollout / deployment
This PR depends on the additive
glaas-apiGET /api/v1/auth/meendpoint.Deployment order:
glaas-apiroarIf
roaris deployed first, it will fall back to existing anonymous public behavior rather than breaking.No downtime expected.
Risks