Kubelet HTTPS is disabled

Protect management traffic between the API server and kubelet with HTTPS.

Description

In older kube-apiserver versions, --kubelet-https=false selects HTTP for connections from the API server to the kubelet.

Potential impact

Logs and node management requests or responses can be read or modified along that unprotected connection.

Remediation

Remove the HTTP override on versions that support it. Configure the API server to connect over HTTPS and verify the kubelet’s serving certificate against a trusted CA. Configure client authentication and authorization on the kubelet. Check that normal management operations succeed and an untrusted serving certificate is rejected.

Examples

The Kubernetes 1.6.0 excerpts remove only the HTTP override. Certificate verification is configured separately. Use the settings supported by your cluster version.

Before

yaml
apiVersion: v1
kind: Pod
metadata:
  name: command-demo
spec:
  containers:
    - name: command-demo-container
      image: gcr.io/google_containers/kube-apiserver-amd64:v1.6.0
      command: ["kube-apiserver"]
      args: ["--kubelet-https=false"]

After

yaml
apiVersion: v1
kind: Pod
metadata:
  name: command-demo
spec:
  containers:
    - name: command-demo-container
      image: gcr.io/google_containers/kube-apiserver-amd64:v1.6.0
      command: ["kube-apiserver"]

References