---
inputType: "CA10__CaAwsAcmCertificate__c"
testData:
  - file: test-data.json
importExtracts:
  - file: /types/CA10__CaAwsAcmCertificate__c/object.extracts.yaml
conditions:
  - status: "INAPPLICABLE"
    currentStateMessage: "The certificate is not active."
    check:
      NOT_EQUAL:
        left:
          EXTRACT: "CA10__status__c"
        right:
          TEXT: "ISSUED"
  - status: "INCOMPLIANT"
    currentStateMessage: "The certificate key length is smaller than 2,048 bits."
    remediationMessage: "Consider deleting the certificate with a key length smaller than 2,048 bits."
    check:
      IS_EQUAL:
        left:
          EXTRACT: "CA10__keyAlgorithm__c"
        right:
          TEXT: "RSA-1024"
otherwise:
  status: "COMPLIANT"
  currentStateMessage: "The certificate uses a key length of at least 2,048 bits."
