Why it matters
Granting a role to a namespace's default service account grants it to every pod in that namespace that does not name another account.
How to fix it
Create a dedicated service account for the workload that needs the role and bind that instead.
What TrustIvan reads
Read through the Kubernetes API with the read-only role TrustIvan's install creates.
Benchmark controls
- CIS Kubernetes Benchmark 1.9.0, control
5.1.5: Default service accounts are not actively used. Also checked for this control: Default service account does not turn off token automounting, Workload runs as the default service account
Control numbers are the published ones; the titles are TrustIvan's own short descriptions. The benchmarks belong to their publishers, who do not endorse TrustIvan.
Related checks
- Role can approve certificate signing requests
KubernetesSeverity: Medium
k8s.rbac.csr-approve - Role can escalate, bind or impersonate
KubernetesSeverity: High
k8s.rbac.escalate-bind-impersonate - cluster-admin is granted
KubernetesSeverity: High
k8s.rbac.cluster-admin-binding - Role can use the nodes/proxy subresource
KubernetesSeverity: Medium
k8s.rbac.node-proxy - A binding grants access to unauthenticated users
KubernetesSeverity: Critical
k8s.rbac.anonymous-access - Role can create pods
KubernetesSeverity: Medium
k8s.rbac.pod-create
Terms: KSPM (Kubernetes security posture management), Kubernetes RBAC, NSA/CISA Kubernetes Hardening Guidance, CIS Benchmarks
All Kubernetes posture checks · The whole catalogue · How this works in TrustIvan · Documentation