π§ AWS API Gateway REST API Stage is not configured to use an SSL certificate for authentication - prod.logic.yaml π’
- Contextual name: π§ prod.logic.yaml π’
- ID:
/ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml
- Located in: π AWS API Gateway REST API Stage is not configured to use an SSL certificate for authentication π’
Flagsβ
- π’ Logic test success
- π’ Logic with extracts
- π’ Logic with test data
Input Typeβ
Type | API Name | Extracts | Extract Files | Logic Files | |
---|---|---|---|---|---|
π | π AWS API Gateway Stage | CA10__CaAwsApiGatewayStage__c | 3 | 1 | 3 |
Usesβ
- π AWS API Gateway Method - object.extracts.yaml
- π AWS API Gateway API - object.extracts.yaml
- π§ͺ test-data.json
Test Results π’β
Generated at: 2025-04-24T23:44:20.745704888Z Open
Result | Id | Condition Index | Condition Text | Runtime Error |
---|---|---|---|---|
π’ | test1 | βοΈ 99 | βοΈ isDisappeared(CA10__disappearanceTime__c) | βοΈ null |
π’ | test2 | βοΈ 199 | βοΈ not(['restApiStage'].contains(RecordType.DeveloperName)) | βοΈ null |
π’ | test3 | βοΈ 299 | βοΈ extract('CA10__restApi__r.CA10__endpointType__c') == 'PRIVATE' | βοΈ null |
π’ | test4 | βοΈ 399 | βοΈ CA10__restApi__r.CA10A1__AWS_API_Gateway_Methods__r.hasNo(COMPLIANT) | βοΈ null |
π’ | test5 | βοΈ 499 | βοΈ isEmptyLookup('CA10__clientCertificate__r') | βοΈ null |
π’ | test6 | βοΈ 499 | βοΈ isEmptyLookup('CA10__clientCertificate__r') | βοΈ null |
π’ | test7 | βοΈ 499 | βοΈ isEmptyLookup('CA10__clientCertificate__r') | βοΈ null |
π’ | test8 | βοΈ 599 | βοΈ notEmptyLookup('CA10__clientCertificate__r') | βοΈ null |
Generationβ
File | MD5 | |
---|---|---|
Open | /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/policy.yaml | 9C33486220F93D978B807D552A64FE95 |
Open | /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml | F55F8E3578AA1136D16F01215943B31D |
Open | /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/test-data.json | 6A90FE9B918330B473DDC7C73CDA2D15 |
Open | /types/CA10A1__CaAwsApiGatewayMethod__c/object.extracts.yaml | E28695D16341F6C70D3B2EE06BCEB425 |
Open | /types/CA10__CaAwsApiGatewayRestApi__c/object.extracts.yaml | 746F09341E8149BAD88C53E274DB1DD5 |
Generate FULL scriptβ
java -jar repo-manager.jar policies generate FULL /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml
Generate DEBUG scriptβ
java -jar repo-manager.jar policies generate DEBUG /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml
Generate CAPTURE_TEST_DATA scriptβ
java -jar repo-manager.jar policies generate CAPTURE_TEST_DATA /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml
Generate TESTS scriptβ
java -jar repo-manager.jar policies generate TESTS /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml
Execute testsβ
java -jar repo-manager.jar policies test /ce/ca/aws/apigateway/rest-api-stage-ssl-certificate/prod.logic.yaml
Contentβ
---
inputType: "CA10__CaAwsApiGatewayStage__c"
importExtracts:
- file: "/types/CA10__CaAwsApiGatewayRestApi__c/object.extracts.yaml"
testData:
- file: test-data.json
recordTypes:
- "restApiStage"
conditions:
- status: "INAPPLICABLE"
currentStateMessage: "The Stage belongs to a private API endpoint."
check:
IS_EQUAL:
left:
EXTRACT: "CA10__restApi__r.CA10__endpointType__c"
right:
TEXT: "PRIVATE"
- status: "INAPPLICABLE"
currentStateMessage: "The Stage doesn't have HTTP integrations."
check:
RELATED_LIST_HAS_NO:
status: "COMPLIANT"
relationshipName: "CA10__restApi__r.CA10A1__AWS_API_Gateway_Methods__r"
- status: "INCOMPLIANT"
currentStateMessage: "The Stage is not configured to use an SSL certificate."
remediationMessage: "Consider generating an SSL certificate for authentication."
check:
IS_EMPTY_LOOKUP: "CA10__clientCertificate__r"
- status: "COMPLIANT"
currentStateMessage: "The Stage is configured to use an SSL certificate."
check:
NOT_EMPTY_LOOKUP: "CA10__clientCertificate__r"
otherwise:
status: "UNDETERMINED"
currentStateMessage: "Unexpected values in the fields."
relatedLists:
- relationshipName: "CA10__restApi__r.CA10A1__AWS_API_Gateway_Methods__r"
importExtracts:
- file: "/types/CA10A1__CaAwsApiGatewayMethod__c/object.extracts.yaml"
conditions:
- status: "COMPLIANT"
currentStateMessage: "This is an HTTP integration."
check:
OR:
args:
- IS_EQUAL:
left:
EXTRACT: "CA10A1__integrationType__c"
right:
TEXT: "HTTP"
- IS_EQUAL:
left:
EXTRACT: "CA10A1__integrationType__c"
right:
TEXT: "HTTP_PROXY"
otherwise:
status: "INAPPLICABLE"
currentStateMessage: "This is not an HTTP integration."