π§ Google Project has API Keys - prod.logic.yaml π π’
- Contextual name: π§ prod.logic.yaml π π’
- ID:
/ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml
- Located in: π Google Project has API Keys π’
Flagsβ
- π’ Logic test success
- π’ Logic with test data
- π Logic without extracts
Input Typeβ
Type | API Name | Extracts | Extract Files | Logic Files | |
---|---|---|---|---|---|
π | π Google Project | CA10__CaGoogleProject__c | 2 | 1 | 16 |
Usesβ
- π§ͺ test-data.json
Test Results π’β
Generated at: 2025-04-24T23:47:17.790536261Z Open
Result | Id | Condition Index | Condition Text | Runtime Error |
---|---|---|---|---|
π’ | a4p1 | βοΈ 199 | βοΈ CA10G1__Google_API_Keys__r.has(INCOMPLIANT) | βοΈ null |
π’ | a4p2 | βοΈ 200 | βοΈ otherwise | βοΈ null |
Generationβ
File | MD5 | |
---|---|---|
Open | /ce/ca/google/project/api-keys-for-active-services/policy.yaml | 48AFC83D0C49EC30BF5054F4F689CCA9 |
Open | /ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml | 9D140D0E8A7EFDED2D365884DF31F7CE |
Open | /ce/ca/google/project/api-keys-for-active-services/test-data.json | 4F7540DB00DF7B7F42EBEA44EC4B9929 |
Generate FULL scriptβ
java -jar repo-manager.jar policies generate FULL /ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml
Generate DEBUG scriptβ
java -jar repo-manager.jar policies generate DEBUG /ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml
Generate CAPTURE_TEST_DATA scriptβ
java -jar repo-manager.jar policies generate CAPTURE_TEST_DATA /ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml
Generate TESTS scriptβ
java -jar repo-manager.jar policies generate TESTS /ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml
Execute testsβ
java -jar repo-manager.jar policies test /ce/ca/google/project/api-keys-for-active-services/prod.logic.yaml
Contentβ
---
inputType: "CA10__CaGoogleProject__c"
testData:
- file: test-data.json
conditions:
- status: "INCOMPLIANT"
currentStateMessage: "API Keys exist for a project."
remediationMessage: "To avoid the security risk in using API keys, it is recommended to use standard authentication flow instead."
check:
RELATED_LIST_HAS:
status: "INCOMPLIANT"
relationshipName: "CA10G1__Google_API_Keys__r"
otherwise:
status: "COMPLIANT"
currentStateMessage: "API keys are not created for a project."
relatedLists:
- relationshipName: "CA10G1__Google_API_Keys__r"
conditions: []
otherwise:
status: "INCOMPLIANT"
currentStateMessage: "API Key exists."