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
Support all key algs with structured authn config #123282
Conversation
Signed-off-by: Monis Khan <mok@microsoft.com>
ret.OIDCSigningAlgs = []string{ | ||
oidc.RS256, | ||
oidc.RS384, | ||
oidc.RS512, | ||
oidc.ES256, | ||
oidc.ES384, | ||
oidc.ES512, | ||
oidc.PS256, | ||
oidc.PS384, | ||
oidc.PS512, | ||
} |
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.
Should we just have an exported function in oidc.go
that returns keys from
kubernetes/staging/src/k8s.io/apiserver/plugin/pkg/authenticator/token/oidc/oidc.go
Lines 201 to 211 in 7ec1a89
var allowedSigningAlgs = map[string]bool{ | |
oidc.RS256: true, | |
oidc.RS384: true, | |
oidc.RS512: true, | |
oidc.ES256: true, | |
oidc.ES384: true, | |
oidc.ES512: true, | |
oidc.PS256: true, | |
oidc.PS384: true, | |
oidc.PS512: true, | |
} |
Then we don't have to maintain the list in 2 places.
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.
Done.
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 think we can add a test in https://github.com/aramase/kubernetes/blob/15c02f2a034d23174d7c9ef1bb61982cc36126a5/pkg/kubeapiserver/options/authentication_test.go#L448 to validate expected config with --authentication-config
flag.
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.
This is not a blocker for the PR. I can do this in a follow-up.
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.
Done.
Signed-off-by: Monis Khan <mok@microsoft.com>
d07f1f9
to
b5e0068
Compare
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.
/lgtm
/approve
LGTM label has been added. Git tree hash: cf794323380511d17757850a178ef08384f9a097
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: enj, liggitt The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
1 similar comment
/retest |
/retest |
|
/retest |
The Kubernetes project has merge-blocking tests that are currently too flaky to consistently pass. This bot retests PRs for certain kubernetes repos according to the following rules:
You can:
/retest |
/kind bug
/assign aramase
/triage accepted
/priority important-soon