Skip to content

Emit sub_id (RFC 9493) with the user's upstream identity in access tokens #6900

Closed

Description

@jhrozek

Part of #6886.

Problem: a client that hosts sessions for a user (for example Mecatl) needs to know which person at the company identity provider a token belongs to, so it can make that person the owner of their sessions. The access tokens this authorization server issues carry only its own sub.

Change:

  • Add sub_id (RFC 9493) to access tokens issued at login: {"format": "iss_sub", "iss": "<upstream issuer>", "sub": "<upstream subject>"}.
  • The value comes from the authenticated upstream identity at the callback, never from client input or a request parameter.
  • Omitted for synthetic identities (an upstream with no stable subject, for example an OAuth2 provider without userinfo).
  • Configurable per client or audience, so the upstream identity is not disclosed where it is not wanted.
  • No dependency on token-exchange work.

Acceptance: a token from an OIDC upstream login carries the correct issuer and subject pair; a synthetic login carries no sub_id; a client not configured for it receives none.

Activity

  1. added
    needs-triage
    on Oct 21, 2026
  2. removed
    needs-triage
    on Oct 22, 2026
  3. self-assigned this
    on Oct 22, 2026
  4. added 2 commits that reference this issue on Oct 22, 2026
    c541010
    eea13bb
  5. added a commit that references this issue on Oct 23, 2026
    5c8427b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions