More Info:
Pods that automount service account tokens without needing them expand the attack surface. Token mounting should be disabled where API access is not required.Risk Level
MediumAddress
SecurityCompliance Standards
- CIS GKE
Triage and Remediation
- Remediation
Remediation
Manual Steps
Manual Steps
-
Identify pods and service accounts that do not need API access
- On any machine with kubectl access:
- Based on application knowledge, list pods and service accounts that never call the Kubernetes API.
- On any machine with kubectl access:
-
Disable token automount on service accounts that do not need API access
- On any machine with kubectl access, for each such service account:
- For GitOps or manifest-based management, edit the ServiceAccount manifest and add:
then apply:
- On any machine with kubectl access, for each such service account:
-
Disable token automount on pods that do not need API access (per‑pod override)
- For standalone pods:
(This affects the existing pod; ensure your controllers or manifests won’t immediately recreate it without the setting.)
- For standalone pods:
-
Disable token automount on controllers (Deployments, StatefulSets, DaemonSets, Jobs, CronJobs)
- On any machine with kubectl access, for each controller whose workloads do not require API access:
- Edit
deployment.yamland underspec.template.specadd: - Apply the change:
- Repeat similarly for other controller kinds:
Edit each file under
spec.template.specand addautomountServiceAccountToken: false, then:
- On any machine with kubectl access, for each controller whose workloads do not require API access:
-
Review for exceptions where API access is required
- Confirm you did not change service accounts or pods that legitimately need to call the Kubernetes API (e.g., controllers, operators, metrics collectors).
- For critical namespaces (like
kube-system), review individually before applying changes:
-
Verification
- On any machine with kubectl access, re-run a refined audit to list only pods still mounting tokens:
- Confirm that pods and service accounts which do not need API access no longer appear with
automountServiceAccountTokenset (either missing ortrue).
- On any machine with kubectl access, re-run a refined audit to list only pods still mounting tokens:
Using kubectl
Using kubectl
Automation
Automation

