feat(kms): add multi-instance MPC key provider - #838
Draft
kvinwang wants to merge 122 commits into
Draft
Conversation
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.
Summary
Identity chain
The measured workload pins
key_provider_id.GetMetaexposes the committed group public keys, threshold-signed epoch manifest, and local node evidence. The manifest binds each member's endpoint, quote-bound RA-TLS key, and public-share commitment. The live TEE quote then proves possession of the authorized TLS key.No MPC member loads, reconstructs, or exports a complete root private key.
Verification
cargo test -p dstack-kms --no-fail-fast— 58 passedcargo test -p ra-tls --no-fail-fast— 16 passedcargo check --workspacecargo check -p dstack-kmsafter rebasing onto currentmastergit diff --checkThe long KMS integration test executes real CGGMP 3-of-5 K-256 and P-256 threshold operations with two nodes offline and verifies the externally assembled root certificate.
Deployment note
A new MPC genesis rotates
key_provider_idand derived application keys. Existing encrypted disks require an application-level migration; this PR intentionally provides no API that reconstructs or imports a complete root key.Remaining validation