Switch RBAC escalation check to use active authorizer#56358
Switch RBAC escalation check to use active authorizer#56358k8s-github-robot merged 1 commit intokubernetes:masterfrom
Conversation
|
cc @kubernetes/sig-auth-pr-reviews |
|
cc @cjcullen |
f961f68 to
cab5f75
Compare
There was a problem hiding this comment.
Should these errors be logged?
|
/retest |
1 similar comment
|
/retest |
|
/approve |
|
lgtm. I have no preference about logging since its a wholely internal request that attempts a secondary path on errors, but I'll leave it to you. |
|
LGTM |
|
A GKE test showing this works would be nice. |
cab5f75 to
30728d3
Compare
|
/retest |
@cjcullen thoughts on how to write this? as far as I can tell, the e2e user is given superuser permissions by the cluster setup, and service accounts don't have GKE IAM permissions |
e3b4b73 to
2719b6a
Compare
There was a problem hiding this comment.
Do these return false lines merit a log (at least an Info.V4)? If we can't pull a user/requestInfo off the context in this call, something is broken, right?
There was a problem hiding this comment.
Might help the upkeep of these tests to add a little meat to the comments (like if we decide to switch the order of the escalation checks or something).
// Superuser: Can create/update role w/o escalation, so authorizer is not called, and create/update call should succeed.
// Unauthorized: Bob must escalate to create/update the role. When he doesn't have "escalate" permission, the calls should fail.
// Authorized: Bob must escalate to create/update the role. When he does have "escalate permission, the calls should succeed.
// Implicitly authorized: Alice ...
Actually, I wasn't sure why the Alice thing worked the way it did. I'll take another look in a little bit.
There was a problem hiding this comment.
made it a table test, added more descriptions
2719b6a to
1790611
Compare
|
Pretty much LGTM. I still want to bikeshed on where the verb should live (and if "escalate" is the right name). I think we should bring it up at the next sig-auth. |
|
/lgtm |
|
/retest Review the full test history for this PR. Silence the bot with an |
7 similar comments
|
/retest Review the full test history for this PR. Silence the bot with an |
|
/retest Review the full test history for this PR. Silence the bot with an |
|
/retest Review the full test history for this PR. Silence the bot with an |
|
/retest Review the full test history for this PR. Silence the bot with an |
|
/retest Review the full test history for this PR. Silence the bot with an |
|
/retest Review the full test history for this PR. Silence the bot with an |
|
/retest Review the full test history for this PR. Silence the bot with an |
1790611 to
1034efd
Compare
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cjcullen, deads2k, liggitt The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/retest Review the full test history for this PR. Silence the bot with an |
|
[MILESTONENOTIFIER] Milestone Pull Request Labels Incomplete @cjcullen @deads2k @ericchiang @liggitt Action required: This pull request requires label changes. If the required changes are not made within 3 days, the pull request will be moved out of the v1.12 milestone. priority: Must specify exactly one of |
|
Automatic merge from submit-queue (batch tested with PRs 64688, 64451, 64504, 64506, 56358). If you want to cherry-pick this change to another branch, please follow the instructions here. |
Closes #43409