More Info:
Verifies that the API server —profiling argument is set to false. Profiling exposes detailed system and program data that could aid an attacker.Risk Level
MediumAddress
SecurityCompliance Standards
- CIS Kubernetes
Triage and Remediation
- Remediation
Remediation
Manual Steps
Manual Steps
-
On every control plane node, open the API server static pod manifest for editing:
-
In the
command:orargs:list forkube-apiserver, locate any existing--profilingflag and change it to:If no--profilingflag is present, add this line under the other arguments, for example: -
Save and exit the editor. The kubelet will automatically detect the manifest change and restart the
kube-apiserverstatic pod; expect a brief API server disruption during this restart. -
After 30–60 seconds, verify on the same control plane node that the
kube-apiserverprocess is now running with--profiling=false: -
In the command output, confirm that
--profiling=falseappears and that there is no--profiling=trueflag. Repeat steps 1–4 on every control plane node.
Using kubectl
Using kubectl
kubectl cannot modify the kube-apiserver static pod manifest or its process flags, so this finding cannot be fixed through the Kubernetes API. The change must be made directly on every control plane node in
/etc/kubernetes/manifests/kube-apiserver.yaml; see the Manual Steps section for the exact procedure.Automation
Automation

