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

Native support for key rotation in verifications #170

Closed
wants to merge 1 commit into from

Commits on Mar 4, 2022

  1. Native support for key rotation in verifications

    Add native support for key rotation for ES*, Ed*, HS*, RS*, and PS*
    verifications.
    
    In those SigningMethod's Verify implementations, also allow the key to
    be the type of the slice of the supported key type, so that the caller
    can implement the KeyFunc to return all the accepted keys together to
    support key rotation.
    
    While key rotation verification can be done on the callers' side without
    this change, this change provides better performance because:
    
    - When trying the next key, the steps before actually using the key do
      not need to be performed again.
    
    - If a verification process failed for non-key reasons (for example,
      because it's already expired), it saves the effort to try the next
      key.
    
    The native key rotation support also helps callers to get more accurate
    errors.
    fishy committed Mar 4, 2022
    Configuration menu
    Copy the full SHA
    12abf75 View commit details
    Browse the repository at this point in the history