More Info:
The ability to create pods can be abused to run arbitrary workloads and escalate privileges. Restrict create access on pod objects to trusted subjects only.Risk Level
HighAddress
SecurityCompliance Standards
- CIS EKS
Triage and Remediation
- Remediation
Remediation
Manual Steps
Manual Steps
-
List all Roles/ClusterRoles that can create pods
- Run on: any machine with kubectl access
Review each listed Role/ClusterRole to determine which subjects (users/groups/serviceaccounts) really need to create pods. -
Inspect a specific ClusterRole’s permissions
- Run on: any machine with kubectl access
Replace CLUSTERROLE_NAME with the actual name:
Identify rules whereresourcesincludespodsandverbsincludescreate. - Run on: any machine with kubectl access
-
Remove
createon pods from a ClusterRole that should not have it- Run on: any machine with kubectl access
Edit the ClusterRole:
In eachrulesentry that hasresources: ["pods", ...](or includespods), removecreatefrom theverbslist (keep other verbs likeget,list,watchif still required), then save and exit. - Run on: any machine with kubectl access
-
Adjust namespace-scoped Roles similarly
- Run on: any machine with kubectl access
For each namespace where Roles were identified:
Inrules, removecreatefromverbswhereverresourcesincludespods. Save when done. - Run on: any machine with kubectl access
-
Re-verify there are no unintended subjects that still require pod creation
- Run on: any machine with kubectl access
For any remaining Roles/ClusterRoles that must retainpodscreateaccess (e.g., system components or trusted CI/CD), document the justification and ensure their RoleBindings/ClusterRoleBindings are scoped only to the required subjects:
Tighten bindings as needed (edit or delete) so only trusted subjects retain this access. - Run on: any machine with kubectl access
-
Verification
- Run on: any machine with kubectl access
Confirm that any remainingpodscreatepermissions correspond only to explicitly approved, trusted Roles/ClusterRoles.
Using kubectl
Using kubectl
On any machine with kubectl access:Example after (remove If a rule is only for (Repeat for each edited file.)
- Identify Roles/ClusterRoles that can create pods
- For each offending Role/ClusterRole, fetch its manifest
- Namespaced Role (replace NAMESPACE and ROLE_NAME):
- ClusterRole (replace CLUSTERROLE_NAME):
- Edit the manifest(s) locally to remove
createfrom any rule that grants it onpods.
create):create on pods, delete that rule block entirely.- Apply the updated manifest(s)
- Re-run the verification
Automation
Automation

