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: Add script to regenerate JWKs for LMS asymmetric JWT signing #32025

Closed
wants to merge 2 commits into from

Conversation

timmc-edx
Copy link
Contributor

Roll keys used for devstack and tests. These keys have the full set of optional precomputed parameters (p, q, dp, dq, qi) which makes them suitable for use with PyJWT and some other libraries. (pyjwkest allowed the use of a partial set of optional params, but other libraries throw.)

This is preparatory to rolling JWKs in stage and prod, which clears the way for discontinuing use of pyjwkest.

Also:

  • Remove signing JWK from CMS devstack, as per TODO

Roll keys used for devstack and tests. These keys have the full set of
optional precomputed parameters (p, q, dp, dq, qi) which makes them
suitable for use with PyJWT and some other libraries. (pyjwkest allowed
the use of a partial set of optional params, but other libraries throw.)

This is preparatory to rolling JWKs in stage and prod, which clears the way
for discontinuing use of pyjwkest.

Also:

- Remove signing JWK from CMS devstack, as per TODO
Comment on lines +1 to +2
#!/usr/bin/env python
# Generate public/private JWKs for asymmetric JWTs (RSA 4096).
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out this is somewhat redundant with the existing generate_jwt_signing_key management command, but there's a bit of a chicken-and-egg problem as that command still needs to be converted over to use PyJWT. That might mean dropping the nice "add to existing key set" feature. In the meantime this PR will just have to serve as reference (and a working source of keys), while I do a key rotation.

@timmc-edx
Copy link
Contributor Author

This PR is superseded by #32089, which enhances the existing keys.

@timmc-edx timmc-edx closed this Apr 26, 2023
@timmc-edx timmc-edx deleted the timmc/gen-jwks branch April 26, 2023 20:08
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.

None yet

1 participant