π§ AWS IAM AWSCloudShellFullAccess Policy is attached - prod.logic.yaml π’
- Contextual name: π§ prod.logic.yaml π’
- ID:
/ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml
- Located in: π AWS IAM AWSCloudShellFullAccess Policy is attached π’
Flagsβ
- π’ Logic test success
- π’ Logic with extracts
- π’ Logic with test data
Input Typeβ
Type | API Name | Extracts | Extract Files | Logic Files | |
---|---|---|---|---|---|
π | π AWS IAM Policy | CA10__CaAwsIamPolicy__c | 6 | 1 | 3 |
Usesβ
Test Results π’β
Generated at: 2025-04-24T23:44:52.905257981Z Open
Result | Id | Condition Index | Condition Text | Runtime Error |
---|---|---|---|---|
π’ | test1 | βοΈ 99 | βοΈ isDisappeared(CA10__disappearanceTime__c) | βοΈ null |
π’ | test2 | βοΈ 199 | βοΈ extract('CA10__name__c') != 'AWSCloudShellFullAccess' | βοΈ null |
π’ | test3 | βοΈ 299 | βοΈ CA10__AWS_IAM_Role_Policy_Attachments__r.has(INCOMPLIANT) | βοΈ null |
π’ | test4 | βοΈ 300 | βοΈ otherwise | βοΈ null |
π’ | test5 | βοΈ 300 | βοΈ otherwise | βοΈ null |
π’ | test6 | βοΈ 300 | βοΈ otherwise | βοΈ null |
Generationβ
File | MD5 | |
---|---|---|
Open | /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/policy.yaml | 0D521E78AB0752EF9203C8492679759F |
Open | /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml | 260A9C3BD1DA546E1F70D2E4B5523DFE |
Open | /types/CA10__CaAwsIamPolicy__c/object.extracts.yaml | C48327B50CE4EB54B3C6B2B464134BB3 |
Open | /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/test-data.json | EC23AD1C2566AEA6DAD8CD6295140BC6 |
Generate FULL scriptβ
java -jar repo-manager.jar policies generate FULL /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml
Generate DEBUG scriptβ
java -jar repo-manager.jar policies generate DEBUG /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml
Generate CAPTURE_TEST_DATA scriptβ
java -jar repo-manager.jar policies generate CAPTURE_TEST_DATA /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml
Generate TESTS scriptβ
java -jar repo-manager.jar policies generate TESTS /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml
Execute testsβ
java -jar repo-manager.jar policies test /ce/ca/aws/iam/detach-aws-cloudshell-full-access-policy/prod.logic.yaml
Contentβ
---
inputType: "CA10__CaAwsIamPolicy__c"
testData:
- file: "test-data.json"
importExtracts:
- file: "/types/CA10__CaAwsIamPolicy__c/object.extracts.yaml"
conditions:
- status: "INAPPLICABLE"
currentStateMessage: "This is not a AWSCloudShellFullAccess policy."
check:
NOT_EQUAL:
left:
EXTRACT: "CA10__name__c"
right:
TEXT: "AWSCloudShellFullAccess"
- status: "INCOMPLIANT"
currentStateMessage: "AWSCloudShellFullAccess policy is attached to a role."
remediationMessage: "Consider detaching the AWSCloudShellFullAccess policy."
check:
RELATED_LIST_HAS:
status: "INCOMPLIANT"
relationshipName: "CA10__AWS_IAM_Role_Policy_Attachments__r"
otherwise:
status: "COMPLIANT"
currentStateMessage: "AWSCloudShellFullAccess policy is not attached."
relatedLists:
- relationshipName: "CA10__AWS_IAM_Role_Policy_Attachments__r"
conditions:
- status: "INCOMPLIANT"
currentStateMessage: "AWSCloudShellFullAccess policy is attached to a role."
remediationMessage: "Consider detaching the AWSCloudShellFullAccess policy."
check:
NOT_EMPTY_LOOKUP: "CA10__role__r"
otherwise:
status: "COMPLIANT"
currentStateMessage: "AWSCloudShellFullAccess policy is not attached."