source-cooperative / source-cooperative/data.source.coop

feat(federation): optional per-product inline session policy

Open
#143 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Rust
Stars
24
Forks
6
Avg merge
1h 32m
Merged PRs (30d)
1

Description

Part of the Federated backend authentication epic (proxy-side).

What

For connections using subject_scope = product, optionally pass an inline session policy on AssumeRoleWithWebIdentity that scopes the session to {base_prefix}{mirror_prefix}*. This adds a proxy-side blast-radius control on top of the customer's trust policy.

Why it's "free" here

A product-scoped connection already pays per-product cache cardinality, so adding a per-product session policy doesn't change the cache key class. For connection/account scope, mint no session policy (keeps the credential broad and cacheable) — the Source-owned bucket relies on Layer-1 authz + path-prefix rewriting instead.

Acceptance
  • product scope → session policy scoping to the product prefix
  • connection/account scope → no session policy
  • Session-policy fingerprint included in the cache key
  • Test: session policy denies access outside the product prefix

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the proxy-side AssumeRoleWithWebIdentity flow and the cache-key construction, then trace how product, connection, and account scopes are handled. Done means product scope sends a prefix-limited session policy with its fingerprint in the cache key, while connection and account scopes send none, with a test denying access outside the product prefix.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, rust
Domain
authentication, backend-api-design, cloud, security
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.