Federation preserves authority boundaries
Authenticate foreign identity authorities and map their subjects without silently merging namespaces or permissions.
On this page
The question for today
What you’ll understand
- Distinguish trusting a foreign issuer from authorizing all its subjects.
- Explain authenticated bundle delivery and domain binding.
- Prevent namespace collisions in cross-domain principal mappings.
Federation lets one system evaluate identity evidence issued by another authority. It expands the set of trusted provenance sources, not automatically the set of permitted actions. A foreign subject may have the same short name as a local one without being equivalent. Treat trust establishment, principal mapping, and resource authorization as three explicit decisions, each with its own rotation, failure, and audit behavior.
The foreign authority needs an authenticated binding
SPIFFE federation distributes trust bundles for named trust domains through configured bundle endpoints and authentication profiles. A verifier needs to know which domain the retrieved bundle belongs to and why it trusts that endpoint. A valid HTTPS response from some server does not automatically authorize it to supply another domain's roots. Preserve the configured endpoint-profile-domain binding when storing and disseminating bundles, and follow the supported bootstrap and rotation rules of the selected profile.
Federated token validation similarly needs an exact trusted issuer and its supported key-discovery contract. Do not let an incoming token invent a new issuer or key endpoint that the verifier automatically trusts. Discovery retrieves metadata within a preauthorized relationship; it is not a grant of authority to every reachable URL. Key selection, audience, subject semantics, and algorithm rules still apply. A successful foreign signature check remains an authentication result whose authorization scope must be separately defined.
Mapping is a privilege boundary
Map foreign issuer-subject pairs to local roles or principals under an explicit allow-list or constrained rule. Mapping every subject named admin to a local administrator merges unrelated namespaces and lets a foreign naming convention define local privilege. Include environment, tenant, and stable subject semantics where required, and consider what happens if the foreign issuer reassigns a subject. Federation may depend on an external authority whose compromise or configuration mistake now affects a local resource.
A many-to-one mapping can be intentional, such as several service replicas assuming one narrow reader role, but its audit and containment costs remain. Preserve original validated actor and issuer information where the protocol supports it. Removing a federation relationship must also address already issued local tokens and sessions; deleting the trust configuration does not necessarily invalidate every artifact derived earlier. Test both direct foreign authentication and any token-exchange path that creates a new local credential.
Rotation and outage must not erase the checks
Fetch and refresh foreign trust material with authenticated transport and bounded caching appropriate to the specification. During rotation, overlap and retirement need coordinated validation so legitimate workloads continue and removed roots actually stop being trusted. A failed fetch should follow a defined cached-trust and expiry policy, not disable signature checking. Observe bundle age, accepted issuer set, rejected foreign principals, and derived local credentials without retaining reusable secret contents in logs.
The reliability lab provides only an availability contrast. Reset and set both n=5, k=2, predict three up with majority three, then inspect. Reset and re-set n=5, k=3 to predict only two up. It models replica counts, not trust bundles or federated agreement. Enough available endpoints do not establish that a bundle belongs to the named domain, and a majority count does not authorize foreign subjects. State the missing cryptographic binding and local mapping before discussing availability tradeoffs.
Work it through
Six scoped principals, two colliding short names
Three foreign issuers each expose subjects reader and operator. Local policy intentionally grants only issuer A/reader and issuer B/reader a narrow read role; no other mapping exists.
There are 3×2=6 issuer-subject pairs. Comparing short names alone collapses them into two labels and loses the distinction that local policy requires.
The configured mapping accepts exactly two pairs into the read role. Issuer C/reader is not accepted even though its subject string matches both permitted readers.
If either accepted issuer can reassign its reader subject, the local trust contract must address that lifecycle. Mapping two pairs into one role also means revocation and audit must preserve which foreign authority supplied each session.
Federation grants scoped trust in provenance and a defined mapping. It must not turn matching names into accidental local privilege.
The living notebook
Explore the model
Interactive lab · reliability
Trust material is more than a reachable count
Reset, set n=5, k=2, predict up 3, majority 3. Reset and re-set n=5, k=3, predict up 2. The replica-count model has no federation roots, endpoint authentication, subject mapping, or key rotation.
- Available replicas
- 4 of 5
- Majority needed
- 3
- Majority available?
- Yes
A replica count and a majority threshold, without a consensus protocol. Playback highlights fixed replica states. Having a majority alone does not establish linearizability, durability or failure independence. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.
Look forAvailability and a valid authority-to-bundle binding are different requirements.
Pause & reason
Check your understanding
Your turn
Try it yourself
Two issuers each use subject deployment-bot. A resource policy compares only that subject and grants production writes. Explain the unintended trust expansion and name a test that should fail.
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
Preserve issuer context and distinguish staging from production authority.
Compare with the solution
A staging or unrelated issuer can obtain production write access through a colliding short name, even if its tokens are honestly signed. Match the intended issuer-subject pair and the required audience, then enforce resource policy. A valid deployment-bot token from the unapproved issuer should fail that mapping or authorization test, rather than inheriting the production bot's permissions.
Keep the idea
Take it with you
- Foreign trust material must remain bound to the intended authority.
- Federation authentication does not automatically authorize every foreign principal.
- Mappings, derived sessions, and trust rotation need explicit lifecycle rules.
Read further
Original sources and deeper explanations to follow at your own pace.
Optional progress, saved in this browser when available. Revisit any lesson at any time.
Lesson not marked complete.