SV-242387r717013_rule
V-242387
SRG-APP-000033-CTR-000095
CNTR-K8-000330
CAT I
10
Edit the Kubernetes Kubelet file in the --config directory on the Kubernetes Master Node. Set the argument --read-only-port to 0.
Reset Kubelet service using the following command:
service kubelet restart
If using worker node arguments, edit the kubelet service file /usr/lib/systemd/system/kubelet.service.d/10-kubeadm.conf on each Worker Node: set the parameter in KUBELET_SYSTEM_PODS_ARGS variable to
"--read-only-port=0".
Run the following command on each Worker Node:
ps -ef | grep kubelet
Verify that the --read-only-port argument exists and is set to "0".
If the --read-only-port argument exists and is not set to "0", this is a finding.
If the --read-only-port argument does not exist, check the Master Node Kubelet config file.
On the Kubernetes Master Node, run the command:
ps -ef | grep kubelet
(path identified by: --config)
Verify there is a readOnlyPort entry in the config file and it is set to "0".
If the --read-only-port argument exists and is not set to "0" this is a finding.
If "--read-only-port=0" argument does not exist on the worker node and the master node, this is a finding.
V-242387
False
CNTR-K8-000330
Run the following command on each Worker Node:
ps -ef | grep kubelet
Verify that the --read-only-port argument exists and is set to "0".
If the --read-only-port argument exists and is not set to "0", this is a finding.
If the --read-only-port argument does not exist, check the Master Node Kubelet config file.
On the Kubernetes Master Node, run the command:
ps -ef | grep kubelet
(path identified by: --config)
Verify there is a readOnlyPort entry in the config file and it is set to "0".
If the --read-only-port argument exists and is not set to "0" this is a finding.
If "--read-only-port=0" argument does not exist on the worker node and the master node, this is a finding.
M
5376