The alert fired at 03:14. An engineer traced it to a misconfigured Kubernetes RoleBinding. A pod had broader permissions than needed. In the wrong hands, it could have been breach material.
Kubernetes RBAC exists to enforce least privilege. When guardrails are loose, secrets, configs, and workloads are exposed. The fix is not just a static YAML check. It’s the combination of RBAC guardrails, continuous CloudTrail queries, and runbooks that make security enforceable.
RBAC guardrails are your first defense. Define Roles and ClusterRoles tightly. Avoid wildcards like *. Bind only to the groups or service accounts that require the access. Keep manifests under version control. Review changes via pull requests with automated policy checks.
CloudTrail queries close the loop. Even in Kubernetes, AWS IAM and API activity underpin the cluster. Use Athena or CloudWatch Logs Insights to search for unusual actions: role assumptions outside of CI pipelines, privilege escalations, or API calls from unknown IPs. Filter for CreateRole, AttachRolePolicy, and UpdateAssumeRolePolicy events. Run these queries on a schedule and feed the results into alerts.