Skip to main content

More Info:

The kubelet —streaming-connection-idle-timeout argument should not be set to 0. A zero timeout leaves idle streaming connections open indefinitely, enabling denial-of-service.

Risk Level

High

Address

Security

Compliance Standards

  • CIS OKE

Triage and Remediation

Remediation

Manual Steps

  1. On every worker node, check current kubelet process flags to confirm the issue:
    Look for --streaming-connection-idle-timeout=0 in the output.
  2. On every worker node, open the kubelet systemd drop-in configuration for editing:
  3. In that file, locate the KUBELET_KUBECONFIG_ARGS, KUBELET_ARGS, or the ExecStart= line that contains kubelet flags. Ensure the --streaming-connection-idle-timeout flag is either:
    • removed entirely (to use the default), or
    • set to a non-zero duration, for example:
    Save and exit the editor.
  4. If /etc/kubernetes/kubelet-config.json is referenced by kubelet (e.g. via --config=/etc/kubernetes/kubelet-config.json), ensure it does not explicitly set the timeout to 0. Edit on every worker node:
    If present, change:
    to a non-zero duration, for example:
    or remove the line to rely on defaults. Save the file.
  5. On every worker node, reload systemd and restart kubelet (this will temporarily disrupt workloads handled by that node’s kubelet):
  6. Verify on every worker node that kubelet no longer uses a zero timeout:
    Confirm there is no --streaming-connection-idle-timeout=0 flag and, if present, it is set to a non-zero value.
kubectl cannot modify kubelet process flags or the /etc/kubernetes/kubelet-config.json file on worker nodes. To remediate this finding, you must update the kubelet systemd configuration on each worker node and restart kubelet as described in the Manual Steps section.