Skip to content

RFC amendments: service-account claims, token defaults and independent user lifecycle - #1709

Draft
rkoster wants to merge 5 commits into
cloudfoundry:mainfrom
rkoster:rfc-service-accounts-amendments
Draft

rkoster wants to merge 5 commits into
cloudfoundry:mainfrom
rkoster:rfc-service-accounts-amendments

Conversation

@rkoster

@rkoster rkoster commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Draft amendments to the service-account RFC merged in #1645, arising from implementation review in cloudfoundry/cloud_controller_ng#5520.

Proposed changes:

  1. Nested attribution: group all four certificate-derived attribution fields under cf: cf.instance_guid, cf.app_guid, cf.space_guid, cf.org_guid. Update the registration example and owning-org required-claim path together. Issuer and subject remain the authorization identity.
  2. Operator-controlled token validity: make 300 seconds the default rather than an RFC-imposed upper bound. Platform operators may configure a shorter or longer positive duration via BOSH/CAPI. Preserve the cap at the authenticating certificate's expiry and any applicable UAA limits. Developer/account/request overrides are not proposed. Changes must reconcile existing managed registrations and do not revoke issued tokens.
  3. Independent CAPI user lifecycle: first bind provisions only the UAA client. Preserve existing explicit user management and lazy roleless OAuth-user creation on first API use. Disabling, enabling or retiring a service account does not manage independent CAPI users/roles or external WIF identities/grants. Explain retained-role implications for explicit identity reuse. This incorporates the intentional RFC divergence already documented in CAPI #5520.
  4. Timestamp-only reservation observability: retain deletion dates independently of audit retention for future ad hoc queries. No statistics collection, metrics pipeline or age-bucket implementation is required.
  5. GoRouter caller identity: authorize a caller from one identity (app, space, org and service account) taken from a single source, the request's XFCC data, instead of mixing the verified TLS certificate with a forwarded header; this closes a space-scope bypass in the forward/always_forward modes. A certificate has an account only with exactly one well-formed <name>.<prefix>.svc.identity SAN. The compact envoy XFCC format gains a validated SVC=<SAN> element ahead of Subject (a GoRouter extension to RFC 0055's format), and malformed cf:svc: rules are logged as malformed-route-policy.

Rationale

Keep certificate attribution in one namespace, keep one trust source per authorization decision at the router, follow the usual operator-default configuration model, and avoid coupling a workload identity to CAPI user lifecycle when many workloads only use external WIF. Preserve dates needed for later investigation without introducing an observability subsystem.

Status and validation

  • Draft for discussion: these amendments are proposals, not already-approved changes to RFC: Service Accounts for Cloud Foundry Workload Identity #1645. Original metadata/status is preserved; no RFC number or FCP is requested.
  • Independent CAPI user lifecycle and timestamp-only retention are implemented in CAPI #5520. Nested mappings and configurable token validity remain follow-up implementation work; the current registration still uses flat claims and fixed 300-second validity.
  • Verify UAA's dotted-path required-claim matching and managed-client validity reconciliation before claiming implementation completion. Preserve the certificate-expiry cap.
  • The GoRouter rules are tracked in Add qualified service account route sources routing-release#603. This PR also updates RFC 0055's XFCC format description with the proposed SVC= extension and single-source identity rules; the extension is explicitly marked as pending amendment approval.
  • The branch was merged with main to follow the rename to rfc-0065-service-accounts.md; the earlier amendment commits are unchanged.
  • Documentation-only: git diff --check passes, and all five JSON examples parse. No product implementation is changed by this PR.

@cloudfoundry/toc — requesting review from App Runtime Interfaces, App Runtime Platform and UAA maintainers on these focused amendments.

Authorize callers from one XFCC-derived identity (app, space, org and service account), add the validated SVC=<SAN> element to the envoy XFCC format, define when a certificate has a service account, and log malformed cf:svc: route policies.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Inbox

Development

Successfully merging this pull request may close these issues.

1 participant