Repository navigation
[release] Keep GitHub App private keys in Key Vault - #9980
Closed
missymessa wants to merge 3 commits into
Closed
missymessa wants to merge 3 commits into
missymessa wants to merge 3 commits into
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: e6793769-8620-4b12-9a94-206a0db5e467
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: e6793769-8620-4b12-9a94-206a0db5e467
Use az rest for the configured App-ID projection and remove the temporary committed regression suite. Keep RSA signing in Key Vault. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 8f29c08e-f8a7-4acf-9ce1-2db3460d9cc5
Member
Author
|
Closing this release-branch backport in favor of letting the Key Vault signing change flow through the normal branch path: main → prerelease → release. This avoids maintaining a separate implementation on release. If the branch merges do not carry the change or stable needs it sooner, we can revisit and backport. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Intent
Correct the GitHub App migration without moving private keys onto build agents. Keep WIF and short-lived installation tokens, read the configured App-ID secret projection for the JWT issuer, and sign only the SHA-256 digest through Azure Key Vault's RSA Sign operation.
The identifier contract is
appIdSecretName/AppIdSecretName(GitHubAppIdSecretNamefor OneLoc), not a hardcoded App/Client ID in YAML. Only the App-ID projection is read.keyNameselects the RSA signing resource; the private-key secret is never retrieved and there is no PEM/local-signing or PAT fallback.Scope and decisions
Updates the independent VS Code helper and localization/release callers to preserve server-side signing and configured App-ID lookup. Applies the corresponding
az restcorrection from merged Arcade #17801. Removes the temporary committed Pester file; focused regression tests were run externally.This servicing branch retains its standalone helper and existing checkout behavior.
The updated helper uses
az rest --query valuefor App-ID retrieval so Azure CLI retains authentication while bypassing the Windows Key Vault secret-model deserialization failure on year-9999 expiry metadata. Only the configured App-ID projection is read; the private-key secret is never retrieved.This update changes repository code/descriptions only; it does not change live credentials, keys, RBAC or Azure pipeline settings, and does not deploy anything.
Validation
az restarguments and configured numeric/Client-ID issuers, JWT signature/lifetime, nonzero/empty/whitespace/throwing lookups, signing failures without fallback, installation paging/selection, GitHub errors and token masking. Main VS Code tests execute its actual inline YAML helper.az rest.git diff --check. Template-expression substitution is confined to validation artifacts; this is not Azure DevOps template compilation.Upstream protected validation
Arcade #17801 is merged. Its protected canary 3140008 passed at main PR head
4c765904c0d948c1a56963f709043870aeb58887: OneLoc and Promotion App-ID lookup, Key Vault signing, installation-token minting, read-only repository access, and token revocation. All 105 mocked tests passed (seven against that head and 98 against older baseline implementations). Temporary canary pipeline authorizations were restored.That is upstream evidence, not an exact-head live run of this PR or full publishing-workflow validation. It does not establish access/key registration for other consumer identities.
Gates before merging
Kept draft for user review.
dotnet-vscode-csharp-release-tags-app-keyprovisioning, active GitHub registration and the release identity's App-ID-read/Sign access. Current provisioning status has not been revalidated; the earlier key-list result is not proof that the key is still missing.Secret Manager PEM rotation does not synchronize RSA signing keys. Preserve in-use keys and coordinate Key Vault/GitHub key rotation rather than assuming PEM rotation updates the signing key.
Tracking: https://dev.azure.com/dnceng/internal/_workitems/edit/12467