Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix proxy support for jwks retrieval #1776

Merged
merged 1 commit into from
Jul 29, 2024
Merged

Conversation

bdehamer
Copy link
Contributor

As part of the provenance generation logic, an OIDC token is retrieved from the GHA issuer in order to populate the claims in the attestation. The process of verifying the OIDC token requires that the JSON Web Key Set (JWKS) for the GHA OIDC issuer is retrieved. The library (jwks-rsa) we were using to retrieve the key set was not respecting the proxy settings of the actions runner. If a user was using a self-hosted runner behind a proxy the request to retrieve the JWKS would fail.

This change re-implements the JWKS look-up to use the @actions/http-client library for the retrieval -- this library has proxy support already included.

Per: actions/attest-build-provenance#156

@bdehamer bdehamer requested a review from a team as a code owner July 26, 2024 22:11
@bdehamer bdehamer force-pushed the bdehamer/jwks-proxy-fix branch from 74d368f to b28406b Compare July 29, 2024 18:11
Copy link

@ejahnGithub ejahnGithub left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@bdehamer bdehamer merged commit 90d9783 into main Jul 29, 2024
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants