Skip to content

OIDC claims: support for GitHub org and repository IDs? #955

@woodruffw

Description

@woodruffw

I'm raising this as a potential enhancement/addition to current set of X.509 extensions used by Sigstore when encapsulating GitHub Actions OIDC claims, based on this comment in the pre-RFC discussion for Sigstore's integration into cargo/crates.io.

At the moment, there are two primary OIDC claims from GitHub Actions-issued tokens that get embedded in Fulcio-issued certificates as X.509v3 extensions:

  1. The SAN itself, which contains the value of job_workflow_ref from the OIDC token
  2. 1.3.6.1.4.1.57264.1.5, which contains the value of the repository claim from the OIDC token (in org/repo "slug" form)

These are sufficient for verification at a point in time, but some threat models may require the assertion that org/repo still refers to the same org and repo. Fortunately, GitHub provides stable numeric identifiers for these, in the form of the repository_id and repository_owner_id claims. These can be used to detect a change in underlying account or repository identity, e.g. in the case an attacker takes over a deleted GitHub account and attempts to release malicious updates with otherwise valid-looking claims.

So, my actual suggestion: we could add two new X.509v3 extensions (and corresponding OIDs):

  • 1.3.6.1.4.1.57264.1.8: GitHub Workflow Repository ID: the stable numeric identifier for the repository the workflow was run under
  • 1.3.6.1.4.1.57264.1.9: GitHub Workflow Repository Owner ID: the stable numeric identifier for the user or organization that owns the repository the workflow was run under

cc @asraa, @znewman01, and @haydentherapper for thoughts!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions