Skip to content

feat: Allow JWT signing keys to be shared (closes #4699)#6537

Draft
keeganwitt wants to merge 1 commit intospiffe:mainfrom
keeganwitt:too_many_jwks_keys
Draft

feat: Allow JWT signing keys to be shared (closes #4699)#6537
keeganwitt wants to merge 1 commit intospiffe:mainfrom
keeganwitt:too_many_jwks_keys

Conversation

@keeganwitt
Copy link
Copy Markdown
Contributor

Pull Request check list

  • Commit conforms to CONTRIBUTING.md?
  • Proper tests/regressions included?
  • Documentation updated?

Affected functionality

  • AWS KMS KeyManager server plugin
  • Azure Key Vault KeyManager server plugin
  • GCP KMS KeyManager server plugin
  • Disk KeyManager server plugin

Description of change
Adds the ability to share signing keys between server instances rather than each instance managing its own key pairs, so that the number of keys that will be exposed in the JWKS endpoint is reduced.

Which issue this PR fixes
#4699

@keeganwitt keeganwitt force-pushed the too_many_jwks_keys branch 2 times, most recently from 61af2e1 to 705e1fb Compare January 8, 2026 15:17
Signed-off-by: Keegan Witt <keeganwitt@gmail.com>
@sorindumitru
Copy link
Copy Markdown
Collaborator

We've discussing this a bit, here's a summary of the discussions so far (at least the parts I remember):

  • Since this may require experimenting we'd like to start with just the changes in the AWS keymanager. Once we get some familiarity with this mode, we can extend it to other plugins.
  • We'd like to keep the plugin implementation be similar for the two different config options (shared and non-shared keys) so that it does not increase the maintenance burden.
  • This may require some changes in other parts of the code. E.g. how key ids are generated. Each server currently generates a random number for it's key so I think that even with this you'll get N keys in the bundle. We'll likely have to make it more deterministic, maybe based on the public key.
  • It's unclear how well this will work with removal from the bundle. It may just work, but it might depend on TTLs and on when a certain key starts being used.
  • Some feature might not work at all with this, e.g. tainting keys. It would be nice to have some kind of support for this, but it may be hard without the servers communicating between each other.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants