Skip to content

Commit 5eb885c

Browse files
authored
Update GitHub thumbprints for OIDC in CI (#2813)
CI uses an `OpenIdConnectProvider` to grant access to certain operations in the CI AWS account to the GitHub Actions runners. This provider checks the certificate thumbprints to validate the authenticity of connect requests. GitHub recently [added a new thumbprint](https://github.blog/changelog/2023-06-27-github-actions-update-on-oidc-integration-with-aws/), which was causing CI and the PR bot to intermittently fail since the OIDC provider wasn't aware of it. This PR corrects the thumbprints to reestablish consistency in CI. ---- _By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice._
1 parent 57459f0 commit 5eb885c

File tree

3 files changed

+1105
-810
lines changed

3 files changed

+1105
-810
lines changed

tools/ci-cdk/lib/oidc-provider-stack.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,13 @@ import { Construct } from "constructs";
1717
///
1818
/// This was done with the initial Idp URL of:
1919
/// https://token.actions.githubusercontent.com/.well-known/openid-configuration
20-
export const GITHUB_CERTIFICATE_THUMBPRINT = "6938FD4D98BAB03FAADB97B34396831E3780AEA1";
20+
///
21+
/// Note: as of June 27, 2023, there are now two possible thumbprints from GitHub:
22+
/// https://github.blog/changelog/2023-06-27-github-actions-update-on-oidc-integration-with-aws/
23+
export const GITHUB_CERTIFICATE_THUMBPRINTS = [
24+
"6938FD4D98BAB03FAADB97B34396831E3780AEA1",
25+
"1C58A3A8518E8759BF075B76B750D4F2DF264FCD",
26+
];
2127

2228
// There can only be one OIDC provider for a given URL per AWS account,
2329
// so put these in their own stack to be shared with other stacks.
@@ -32,7 +38,7 @@ export class OidcProviderStack extends Stack {
3238

3339
this.githubActionsOidcProvider = new OpenIdConnectProvider(this, "oidc-provider", {
3440
url: "https://token.actions.githubusercontent.com",
35-
thumbprints: [GITHUB_CERTIFICATE_THUMBPRINT],
41+
thumbprints: GITHUB_CERTIFICATE_THUMBPRINTS,
3642
clientIds: ["sts.amazonaws.com"],
3743
});
3844
}

0 commit comments

Comments
 (0)