-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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 method to detect public keys without prefixing #2758
Conversation
# Conflicts: # oauth2/handler_test.go # persistence/sql/persister_oauth2.go
Co-authored-by: hackerman <3372410+aeneasr@users.noreply.github.com>
Co-authored-by: hackerman <3372410+aeneasr@users.noreply.github.com>
Timo Doernenburg seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
jwk/helper.go
Outdated
@@ -49,13 +49,6 @@ func AsymmetricKeypair(ctx context.Context, r InternalRegistry, g KeyGenerator, | |||
if err != nil { | |||
return nil, nil, err | |||
} | |||
keys, err := r.KeyManager().GetKeySet(ctx, set) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed this because it served no purpose / did not make sense in this context and had no tests
jwk/jwt_strategy.go
Outdated
@@ -113,7 +114,7 @@ func (j *RS256JWTStrategy) refresh(ctx context.Context) error { | |||
return err | |||
} | |||
|
|||
public, err := FindPublicKey(keys) | |||
public, err := FindKeyByPrefix(keys, "public") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reverted this because we still rely on the private: pattern to be available for private keys.
Codecov Report
@@ Coverage Diff @@
## master #2758 +/- ##
==========================================
- Coverage 52.82% 50.50% -2.32%
==========================================
Files 235 235
Lines 14112 14721 +609
==========================================
- Hits 7454 7435 -19
- Misses 6028 6626 +598
- Partials 630 660 +30
Continue to review full report at Codecov.
|
Closes #2459