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

feat: Implement key derivation for RFC 16 #3568

Draft
wants to merge 34 commits into
base: main
Choose a base branch
from
Draft

Conversation

miampf
Copy link
Contributor

@miampf miampf commented Jan 7, 2025

Context

RFC 16 requires key derivation for the client and all nodes. This PR aims to implement that. For the main PR of this RFC, see #3557 (WIP).

Proposed change(s)

  • Add grpc functionality to request a CA key from the join service
    • This CA key is derived in the key service
    • The join client in the bootstrapper than gets the derived key in the IssueJoinTicketResponse

Additional info

  • The RFC specifies that the CA key should be derived directly from the master secret. This is not the case here. Instead, the key service requests a key from a KMS which in turn is used to derive the CA key. If the cKMS is used, the key sent by the KMS is derived using the master secret.

Checklist

@miampf miampf added the feature This introduces new functionality label Jan 7, 2025
@miampf miampf added this to the v2.21.0 milestone Jan 7, 2025
@miampf miampf requested a review from burgerdev January 7, 2025 16:08
@miampf
Copy link
Contributor Author

miampf commented Jan 7, 2025

Used the feature label instead of no changelog since this PR adds the constellation ssh subcommand for key derivation.

Copy link

netlify bot commented Jan 7, 2025

Deploy Preview for constellation-docs canceled.

Name Link
🔨 Latest commit 0cf04f0
🔍 Latest deploy log https://app.netlify.com/sites/constellation-docs/deploys/677ff8477086b10008bb4d49

cli/internal/cmd/ssh.go Outdated Show resolved Hide resolved
cli/internal/cmd/ssh.go Outdated Show resolved Hide resolved
cli/internal/cmd/ssh.go Outdated Show resolved Hide resolved
cli/internal/cmd/ssh.go Outdated Show resolved Hide resolved
cli/internal/cmd/ssh.go Outdated Show resolved Hide resolved
cli/internal/cmd/ssh.go Show resolved Hide resolved
joinservice/joinproto/join.proto Outdated Show resolved Hide resolved
keyservice/internal/server/server.go Outdated Show resolved Hide resolved
@miampf miampf force-pushed the miampf/key-derivation branch 3 times, most recently from ab5aea6 to 0bd9ac7 Compare January 9, 2025 11:34
@miampf miampf force-pushed the miampf/key-derivation branch from 0bd9ac7 to ced42d5 Compare January 9, 2025 11:53
@miampf miampf requested a review from burgerdev January 9, 2025 14:54
Copy link
Contributor

github-actions bot commented Jan 9, 2025

Coverage report

Package Old New Trend
bootstrapper/internal/initserver 71.70% 67.90% ↘️
bootstrapper/internal/joinclient 87.00% 86.80% ↘️
cli/cmd 0.00% 0.00% 🚧
cli/internal/cmd 57.90% 56.80% ↘️
internal/constants 0.00% 0.00% 🚧
internal/crypto 69.60% 73.30% ↗️
joinservice/internal/server 78.20% 77.10% ↘️
joinservice/joinproto 0.00% 0.00% 🚧

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature This introduces new functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants