-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Remove self-deletion permissions from kubelets #71021
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: 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 |
/milestone v1.13 |
@@ -107,7 +107,7 @@ func NodeRules() []rbacv1.PolicyRule { | |||
// Use the NodeRestriction admission plugin to limit a node to creating/updating its own API object. | |||
rbacv1helpers.NewRule("create", "get", "list", "watch").Groups(legacyGroup).Resources("nodes").RuleOrDie(), | |||
rbacv1helpers.NewRule("update", "patch").Groups(legacyGroup).Resources("nodes/status").RuleOrDie(), | |||
rbacv1helpers.NewRule("update", "patch", "delete").Groups(legacyGroup).Resources("nodes").RuleOrDie(), | |||
rbacv1helpers.NewRule("update", "patch").Groups(legacyGroup).Resources("nodes").RuleOrDie(), |
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.
what binary is this code part of ?
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.
the kube-apiserver, which uses it in the node authorizer and to populate the default system:node
cluster role
/retest |
LGTM 🎉 |
/assign @mikedanese |
We might need to add some legacy RBAC addons to make sure GKE continues to work... I'll discuss with @cjcullen . /lgtm |
bot looks stuck. tagging based on #71021 (comment) |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Removes the ability of kubelets to delete their own Node API objects. Kubelets stopped doing this in 1.11, which means a 1.13 API server no longer needs to grant them this permission.
This closes a method by which a kubelet on a compromised node could delete and recreate its Node object, effectively removing any taints the cluster administrator had added to the Node object.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):xref kubernetes/community#911
xref kubernetes/enhancements#279
Special notes for your reviewer:
Does this PR introduce a user-facing change?:
@kubernetes/sig-auth-pr-reviews
@kubernetes/sig-node-pr-reviews