Repository navigation
Conversation
…ithm docs - docs: state encryption is AES-GCM, recommend 256-bit keys - docs: say that dapr mtls renew-certificate generates an ECDSA P-256 root - docs: EdDSA is not supported for Sentry JWT signing Signed-off-by: joshvanl <me@joshvanl.dev>
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The security documentation updates have no active review issues.
No open issues 🎉
What changed in this PR
This PR corrects Dapr security documentation for state encryption, certificate renewal, and JWT signing.
Changes:
- Documents AES-GCM support and recommends 256-bit keys, updating the key-generation example.
- Clarifies CLI-generated root keys and the SEC 1 PEM requirement for supplied ECDSA keys.
- Lists supported JWT signing algorithms and explains EdDSA failure behavior.
| File | Description |
|---|---|
daprdocs/content/en/reference/cli/dapr-mtls/dapr-mtls-renew-certificate.md |
Clarifies root-key generation and private-key format requirements. |
daprdocs/content/en/operations/security/mtls.md |
Explains CLI certificate-renewal key algorithms and accepted key format. |
daprdocs/content/en/developing-applications/building-blocks/state-management/howto-encrypt-state.md |
Recommends 256-bit keys, updates the example, and fixes a typo. |
daprdocs/content/en/concepts/security-concept.md |
Corrects encryption details and clarifies certificate and JWT signing algorithms. |
Review effort: Balanced
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.
Thank you for helping make the Dapr documentation better!
Please follow this checklist before submitting:
In addition, please fill out the following to help reviewers understand this pull request:
Description
This PR corrects three statements in the security docs. The text names no Dapr version, so it is true for 1.17, 1.18 and 1.19 and can be backported unchanged.
State encryption. The docs said encryption is "based on AES256" and recommended 128-bit keys. Dapr uses AES-GCM, and the key length (16, 24 or 32 bytes) selects AES-128, 192 or 256 (
pkg/encryption/encryption.go). The pages now say AES-GCM, recommend 256-bit keys, and the example generates a 32-byte key. A typo ("errors and exists") is fixed on the same line.dapr mtls renew-certificate. The key algorithm table describes the CA that Sentry generates itself, which is Ed25519 from 1.18. The CLI is different: it generates its root key as ECDSA P-256 on every cli release from v1.17.0 to v1.19.1. The security concept page, the mTLS page and the command reference now say so. They also say that--private-keymust be an ECDSA key in SEC 1 PEM (-----BEGIN EC PRIVATE KEY-----), because the CLI reads it withx509.ParseECPrivateKey.EdDSA for JWT signing. The "JWT signing" paragraph now lists the values that
--jwt-signing-algorithmanddapr_sentry.jwt.signingAlgorithmaccept, and says EdDSA is not supported. Sentry either exits at startup withunsupported signature algorithm: EdDSA(with [PR link: dapr fixes]) or starts and leaves every sidecar without an identity. Both outcomes are described, so the text holds before and after that fix.Design choices for reviewers
--private-keyis new information. A PKCS Improve Actors conceptual docs and add dotnet sdk usage. #8PRIVATE KEYfile fails today.--private-key <existing-root-key>without saying it must be an EC key. Left alone.Testing
lang:lines removed fromhugo.yaml, not the pinned 0.147.8.#root-and-issuer-certificate-upgrade-using-cli-recommendedexists in the built mTLS page.pkg/kubernetes/renew_certificate.goat every cli tag from v1.17.0 to v1.19.1, and daprbundle.GenerateX509and Sentryvalidate.goon release-1.17, 1.18 and 1.19.dapr mtls renew-certificatewas not run against a cluster.Issue reference
None.