Repository navigation
Conversation
…ience
An `s3_web_identity_role` connection may set `audience` to `scv1:conn:{data_connection_id}`, its own subject, instead of the shared `sts.amazonaws.com`. The schema accepts only those two values; any other is a field error on `authentication.audience`, since an audience naming another connection would satisfy the check a role owner registers it for. The form offers the choice next to the role ARN, tells the owner which client ID to register on their OIDC provider, and the trust policy it shows conditions on the chosen audience.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XR9ZJnpPSJFK6LFSBxePNE
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
Claude finished @alukach's task in 13s —— View job ✅ No blocking issues — safe to merge (after the deployment order in the description: multistore#167, then data.source.coop#267, then this PR). I read the diff only and did not run the tests. Notes (non-blocking)
Simplify (ponytail)
DocsThe description covers the docs. It names ADR-012 §1 (still holds, this is its app half), docs.source.coop 💰 Estimated review cost: $0.11 · 0m13s · 4 turns |
This branch was successfully deployed
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.
An
s3_web_identity_roleconnection can now setauthentication.audiencetoscv1:conn:{data_connection_id}, its own subject, instead of the sharedsts.amazonaws.com. AWS checks a token'saudagainst the client IDs registered on the role's IAM OIDC provider before it evaluates the trust policy, so a role owner who registers exactly that value accepts tokens for this connection and no other, whether or not their trust policy pinssub. This is the app half of data.source.coop ADR-012 §1; the proxy half is source-cooperative/data.source.coop#267.The field is optional and absent means the shared audience, so existing connections are unchanged.
DataConnectionSchemaaccepts onlysts.amazonaws.comor the connection's ownscv1:conn:{id}; any other value is a field error onauthentication.audience, because an audience naming another connection would satisfy the check a role owner registers it for. The proxy refuses such a value as well.The form gains an Audience select under the role ARN: Shared (
sts.amazonaws.com) or This connection only. Its help names the client ID to register, and the trust policy shown below it conditions on the chosen audience. The form always submits the audience, so switching back to Shared clears a stored one on edit.Order of deployment
oidc_audienceoption), released.Merging this before the proxy ships is not unsafe, only premature: a proxy without #267 ignores the field and keeps sending
sts.amazonaws.com, so a connection set to its own audience fails at STS once its owner has removed the shared client ID, rather than succeeding under it. It stays a draft until #267 is deployed.Stories
Screenshot to follow once the branch's Storybook deploy is up.
Testing
npx jest src/types/data-connection.test.ts src/components/features/data-connections/trust-policy.test.ts src/lib/operations/data-connections.test.ts: 67 passed. New: the schema accepts no audience,sts.amazonaws.comand the connection's own subject, and rejects another connection's subject, a suffixed subject and an arbitrary string with the error onauthentication.audience; the trust policy conditions on the given audience.npm run type-check: no errors in changed files. The run reports 20 errors, all missing-module errors from the local install, andmainreports the same 20.Docs and ADRs
bring-your-own-bucket: still accurate for the shared audience, which stays the default. The own-audience setup gets a section there once Epic: Access Controls #267 is deployed, so the docs never describe an option the proxy doesn't honour yet.public/llms.txt: no change; no new endpoint, and the field is documented in the OpenAPI schema.🤖 Generated with Claude Code