chore: refactor keycache implementation to reduce duplication (#15100)

This commit is contained in:
Jon Ayers
2024-10-16 20:01:45 +01:00
committed by GitHub
parent 8e254cbb07
commit f537193682
10 changed files with 512 additions and 1339 deletions

View File

@ -27,7 +27,7 @@ type DecryptKeyProvider interface {
func Encrypt(ctx context.Context, e EncryptKeyProvider, claims Claims) (string, error) {
id, key, err := e.EncryptingKey(ctx)
if err != nil {
return "", xerrors.Errorf("get signing key: %w", err)
return "", xerrors.Errorf("encrypting key: %w", err)
}
encrypter, err := jose.NewEncrypter(