feat: generate only authn's RSA private key, not a shared JWT secret - #54
Merged
Conversation
authn now signs RS256 JWTs with an RSA private key and publishes the public key itself via JWKS; consumers no longer need a copy of any key material. secret.yaml generates ONLY the private key (Secret authn-jwt-signing-key, key private.pem, matching authn chart defaults jwt.signKeySecretName/ signKeySecretKey) instead of the old shared jwt-sign-key HMAC secret — a second Secret holding the public key would be one more object to keep in sync and would pin verifiers to a keypair only a redeploy of all of them could rotate. `lookup` still reuses an existing key across re-renders so reconciles never rotate it.
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
authn now signs RS256 JWTs with an RSA private key and publishes the public key itself via JWKS (
GET /.well-known/jwks.json).chart/templates/secret.yamlnow generates only the private key — Secretauthn-jwt-signing-key, keyprivate.pem, matching the authn chart'sjwt.signKeySecretName/jwt.signKeySecretKeydefaults — replacing the old sharedjwt-sign-keyHMAC secret.lookupstill reuses an existing key across re-renders so reconciles never rotate it.A second Secret holding the public key is deliberately NOT created: it would be one more object to keep in sync, and would pin verifiers to a keypair only a redeploy of all of them could rotate. Verifiers (snowplow) fetch the public key from authn's JWKS endpoint instead.
chart/values.schema.jsonupdates the authn/snowplow sub-schemas' JWT config shape to match their new chart values (jwt.{signKeySecretName,signKeySecretKey,mountPath,kid}for authn;jwt.{jwksUrl,cacheTTL,minRefreshInterval,requestTimeout}for snowplow).chart/files/component-pins.yamlalready pinsauthn: 0.26.2/snowplow: 1.9.3onmain(pre-staged for this migration) — no version-pin change needed here, those charts just need to actually exist at those versions before this can be installed end-to-end.Cross-repo dependency — full chain
helm installonly succeeds end-to-end once authn0.26.2and snowplow1.9.3are actually published to the chart OCI registry, i.e. after 2 and 3 are tagged.Test plan
helm lint chart/(with theCHART_VERSION/APP_VERSIONplaceholders substituted, as release-oci.yaml does) — no errors attributable to this changehelm installend-to-end once authn/snowplow charts at the pinned versions are published