Repository navigation
docs(spec): CITrust reconciler on Keycloak 26.x token-exchange v2 (PLAT-DATA-25) - #820
markturansky wants to merge 1 commit into
Conversation
…e v2 Codify the intent of issue #819 (PLAT-DATA-25) in the CI Trust Extension API specification. The reconciler realization moves from the Keycloak fine-grained-authz v1 path, which the production fleet Keycloak 26.x has disabled (501), to the external-to-internal token-exchange v2 mechanism with a public, keyless requester. Changes to specs/platform/ci-trust-ext-api.spec.md (prefix PLAT-CITR): - Rewrite the architecture prose that cited the v1 helper EnsureE2ETokenExchange / enableTokenExchangePermissions as the path to extend; scope the v2 requirement to the production fleet Keycloak and note the v1 helper stays valid only for the separate e2e impersonation subsystem. - PLAT-CITR-01: adopt a platform-provisioned (gitops) IdP instead of creating a parallel one; do not delete it on CIProvider delete (scenario 01.02). Resolves the idp_alias discrepancy. - PLAT-CITR-02: realize the exchange through the v2 admin-REST path with the public federation client; delete reverts the authorization. - PLAT-CITR-04: make the per-repository subject predicate the real trust boundary; audience pinning is necessary but not sufficient (scenario 04.02). - PLAT-CITR-05: deleting a CITrust revokes the exchange (scenario 05.02). - PLAT-CITR-08 (new): Keycloak 26.x external-to-internal token-exchange v2; prohibit the v1 token-exchange and fine-grained-authz-v1 paths. - PLAT-CITR-09 (new): idempotent, re-entrant reconcile whose artifacts survive the realm-reconcile job; fail-closed on unknown Keycloak state. - Update the security analysis and the PLAT-CITR count in specs/ids.md. Whole-tree coherence audit: grepped all of specs/ for token-exchange, EnsureE2ETokenExchange, enableTokenExchangePermissions, fine-grained, management/permissions, external-internal, and Keycloak 26.x. The e2e / PR-environment impersonation specs (ephemeral-pr-environments, ephemeral-test-credentials, e2e-testing) describe a distinct subsystem on its own Keycloak and stay coherent now that the CITrust spec scopes v2 to the production fleet. Other hits (oidc-integration BFF refresh, gateway-console, gateway-service-accounts, hsctl-release) are unrelated uses of the phrase. data-model.spec.md (PLAT-DATA-24/25) kinds are unchanged. Closes #819 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
Spec review:
|
Purpose
This change codifies the intent of issue #819 (PLAT-DATA-25) in the CI Trust
Extension API specification. It specifies the CITrust reconciler against the
Keycloak 26.x external-to-internal token-exchange v2 mechanism. The fine-grained
admin authorization v1 path, which the earlier draft assumed, is disabled on the
production fleet Keycloak and returns HTTP 501. This is a specification change
only; it adds no code.
What changes
In
specs/platform/ci-trust-ext-api.spec.md(prefixPLAT-CITR):(
EnsureE2ETokenExchange/enableTokenExchangePermissions) as the path toextend. The v2 requirement is scoped to the production fleet Keycloak. The v1
helper stays valid only for the separate end-to-end impersonation subsystem.
PLAT-CITR-01: the control plane adopts a platform-provisioned (gitops)identity provider. It does not create a parallel one and does not delete the
provisioned one (scenario
01.02). This resolves theidp_aliasdifference.PLAT-CITR-02: the exchange is realized through the v2 admin-REST path with thepublic federation client. A delete reverts the authorization.
PLAT-CITR-04: the per-repository subject predicate is the trust boundary.Audience pinning is necessary but not sufficient, because any repository can
mint a token that carries the pinned audience (scenario
04.02).PLAT-CITR-05: deleting a CITrust revokes the exchange (scenario05.02).PLAT-CITR-08(new): Keycloak 26.x external-to-internal token-exchange v2. Thev1 token-exchange and fine-grained-authz-v1 paths are prohibited.
PLAT-CITR-09(new): the reconcile is idempotent and re-entrant. Its artifactssurvive the realm-reconcile job. It fails closed on unknown Keycloak state.
PLAT-CITRcount inspecs/ids.mdare updated.Whole-tree coherence audit
All of
specs/was searched for the key terms:token-exchange,EnsureE2ETokenExchange,enableTokenExchangePermissions,fine-grained,management/permissions,external-internal,subject_issuer, and Keycloak26.x.(
ephemeral-pr-environments,ephemeral-test-credentials,e2e-testing)describe a separate subsystem on its own Keycloak. They stay coherent because
the CITrust spec now scopes the v2 requirement to the production fleet Keycloak.
oidc-integrationBFF refresh,openshell-gateway-console,openshell-gateway-service-accounts,hsctl-release) are unrelated uses of thephrase.
data-model.spec.md(PLAT-DATA-24/25) kinds are unchanged.Verification
make check-spec-idspasses.make check-forbidden-termspasses.Closes #819
🤖 Generated with Claude Code