Skip to content

Commit

Permalink
match roleref kind with role kind
Browse files Browse the repository at this point in the history
Signed-off-by: YiscahLevySilas1 <[email protected]>
  • Loading branch information
YiscahLevySilas1 committed May 16, 2024
1 parent 9fc8ff4 commit 75f16b2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions rules/workload-with-cluster-takeover-roles/raw.rego
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ deny[msga] {
rolebinding := input[_]
rolebinding.kind in ["RoleBinding", "ClusterRoleBinding"]
rolebinding.roleRef.name == role.metadata.name
rolebinding.roleRef.kind == role.kind
rolebinding.subjects[j].kind == "ServiceAccount"
rolebinding.subjects[j].name == sa.metadata.name
rolebinding.subjects[j].namespace == sa.metadata.namespace
Expand Down

0 comments on commit 75f16b2

Please sign in to comment.