Skip to main content

More Info:

Configuring a client CA file enables the kubelet to authenticate client certificates against a trusted certificate authority, preventing unverified clients from connecting.

Risk Level

High

Address

Security

Compliance Standards

  • CIS EKS

Triage and Remediation

Remediation

Manual Steps

  1. On every worker node, SSH in and identify how kubelet is configured:
    • If you see a --config=/var/lib/kubelet/config.yaml (or similar) flag, follow Step 2.
    • If you see --client-ca-file=... directly in the arguments and no --config flag, skip to Step 3.
  2. If using /var/lib/kubelet/config.yaml, edit it to set authentication.x509.clientCAFile (create the hierarchy if missing):
    Add or update under the top level:
    Ensure /etc/kubernetes/pki/client-ca.crt exists and contains the intended CA.
  3. If using executable arguments, edit the kubelet systemd drop-in on the worker node:
    In the line that sets kubelet arguments (e.g. KUBELET_ARGS= or ExecStart=), ensure it includes:
    Adjust the path if your client CA is stored elsewhere, and ensure the file exists.
  4. Reload systemd and restart kubelet on the worker node (required for any of the above changes to take effect):
  5. Check kubelet status for errors on the worker node:
  6. Verify kubelet is now running with a client CA configured on the worker node:
    Confirm the output shows either a --config=/var/lib/kubelet/config.yaml (where the file contains authentication.x509.clientCAFile) or a --client-ca-file=/etc/kubernetes/pki/client-ca.crt (or your chosen CA path).
kubectl cannot configure the kubelet’s clientCAFile because this setting lives in the kubelet host-level configuration (/var/lib/kubelet/config.yaml or kubelet service flags) on every worker node. Make this change directly on the nodes as described in the Manual Steps section.