Skip to main content

More Info:

Certificate rotation lets the kubelet automatically renew its client certificate before expiry. Keeping —rotate-certificates enabled avoids outages and long-lived credentials.

Risk Level

High

Address

Security

Compliance Standards

  • CIS Kubernetes

Triage and Remediation

Remediation

Manual Steps

  1. On every worker node, check how kubelet is configured:
    • If you see --config=/var/lib/kubelet/config.yaml in the command, use the config file steps (2–3).
    • If you see a --rotate-certificates=false flag on the command line (often via systemd drop-in), use the systemd steps (4–5). You may need both if both are present.
  2. On every worker node (config file): back up and edit the kubelet config file:
    If you prefer it explicitly enabled, instead ensure a line like this exists under the top-level (YAML aligned with other boolean options):
  3. On every worker node (config file): validate the setting:
  4. On every worker node (systemd flags): back up and edit the kubelet systemd drop-in, if present:
  5. On every worker node: reload systemd and restart kubelet (this restarts the kubelet process and may briefly affect pod scheduling on that node):
  6. On every worker node: verify that --rotate-certificates is not set to false:
    Confirm that there is no --rotate-certificates=false in the output.
kubectl cannot change the kubelet’s --rotate-certificates setting because it is controlled by host-level configuration (/var/lib/kubelet/config.yaml and/or the kubelet systemd unit) on each worker node. Make the change directly on every worker node as described in the Manual Steps section.