๐ง Google Resource Manager Organization has a Redis IAM role assigned - prod.logic.yaml๐ข
- Contextual name: ๐ง prod.logic.yaml๐ข
- ID:
/ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml - Tags:
- ๐ข Logic test success
- ๐ข Logic with extracts
- ๐ข Logic with test data
Usesโ
- ๐ Google Resource Manager Organization
- ๐ Google IAM Role - object.extracts.yaml
- ๐ Google IAM Policy Binding - object.extracts.yaml
- ๐งช test-data.json
Test Results ๐ขโ
Generated at: 2025-10-25T12:02:46.782211093Z Open
| Result | Id | Condition Index | Condition Text | Runtime Error |
|---|---|---|---|---|
| ๐ข | 001 | โ๏ธ 200 | โ๏ธ otherwise | โ๏ธ null |
| ๐ข | 002 | โ๏ธ 199 | โ๏ธ CA10__Google_IAM_Policy_Bindings__r.has(INCOMPLIANT) | โ๏ธ null |
| ๐ข | 003 | โ๏ธ 200 | โ๏ธ otherwise | โ๏ธ null |
Generation Bundleโ
| File | MD5 | |
|---|---|---|
| Open | /ce/ca/google/iam/organization-assigned-redis-role/policy.yaml | 1B36B43AF7817FE07C254561BD2F2688 |
| Open | /ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml | 808F9955AD3F0232E319A99D28F025FE |
| Open | /ce/ca/google/iam/organization-assigned-redis-role/test-data.json | 4927F6D2F5A3513EEA053404F0900C7B |
| Open | /types/CA10__CaGoogleIamRole__c/object.extracts.yaml | 545CD4D347F041DCDD9980D122D63882 |
| Open | /types/CA10__CaGoogleIamPolicyBinding__c/object.extracts.yaml | DA65DB880E2440923287921FF4E70B30 |
Available Commandsโ
repo-manager policies generate FULL /ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml
repo-manager policies generate DEBUG /ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml
repo-manager policies generate CAPTURE_TEST_DATA /ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml
repo-manager policies generate TESTS /ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml
# Execute tests
repo-manager policies test /ce/ca/google/iam/organization-assigned-redis-role/prod.logic.yaml
Contentโ
---
inputType: "CA10__CaGoogleResourceManagerOrganization__c"
testData:
- file: "test-data.json"
conditions:
- status: "INCOMPLIANT"
currentStateMessage: "The organization has at least one Redis IAM role assigned to a principal."
remediationMessage: "Remove the predefined Redis IAM role binding from the organization level."
check:
RELATED_LIST_HAS:
status: "INCOMPLIANT"
relationshipName: "CA10__Google_IAM_Policy_Bindings__r"
otherwise:
status: "COMPLIANT"
currentStateMessage: "Organization doesn't have a predefined Redis IAM role assigned."
relatedLists:
- relationshipName: "CA10__Google_IAM_Policy_Bindings__r"
importExtracts:
- file: "/types/CA10__CaGoogleIamPolicyBinding__c/object.extracts.yaml"
- file: "/types/CA10__CaGoogleIamRole__c/object.extracts.yaml"
recordTypes:
- "caGoogleIamPolicyBindingOrganization"
conditions:
- status: "COMPLIANT"
currentStateMessage: "Empty policy binding."
check:
IS_EMPTY_LOOKUP: "CA10__iamRole__r"
- status: "INCOMPLIANT"
currentStateMessage: "This IAM policy binding grants a predefined Redis role at the organization level."
check:
CONTAINS:
arg:
SET:
itemType: "TEXT"
items:
- "roles/redis.admin"
- "roles/redis.editor"
- "roles/redis.viewer"
search:
EXTRACT: "CA10__iamRole__r.CA10__roleName__c"
otherwise:
status: "COMPLIANT"
currentStateMessage: "This IAM policy binding is not for a predefined Redis role."