๐ง AWS Account Root User MFA is not enabled. - prod.logic.yaml๐ข
- Contextual name: ๐ง prod.logic.yaml๐ข
- ID:
/ce/ca/aws/iam/root-user-mfa/prod.logic.yaml - Tags:
- ๐ข Logic test success
- ๐ข Logic with extracts
- ๐ข Logic with test data
Usesโ
- ๐ AWS IAM User
- ๐ AWS IAM User - credReport.extracts.yaml
- ๐ AWS IAM User - object.extracts.yaml
- ๐งช test-data.json
Test Results ๐ขโ
Generated at: 2026-02-10T22:32:59.914010614Z Open
| Result | Id | Condition Index | Condition Text | Runtime Error |
|---|---|---|---|---|
| ๐ข | a0 | โ๏ธ 99 | โ๏ธ isDisappeared(CA10__disappearanceTime__c) | โ๏ธ null |
| ๐ข | a01 | โ๏ธ 199 | โ๏ธ extract('CA10__userName__c') != 'root' | โ๏ธ null |
| ๐ข | a02 | โ๏ธ 299 | โ๏ธ extract('CA10__credReportMfaActive__c') == true | โ๏ธ null |
| ๐ข | a03 | โ๏ธ 399 | โ๏ธ extract('CA10__credReportPasswordEnabled__c') != true | โ๏ธ null |
| ๐ข | a04 | โ๏ธ 399 | โ๏ธ extract('CA10__credReportPasswordEnabled__c') != true | โ๏ธ null |
| ๐ข | a05 | โ๏ธ 400 | โ๏ธ otherwise | โ๏ธ null |
Generation Bundleโ
| File | MD5 | |
|---|---|---|
| Open | /ce/ca/aws/iam/root-user-mfa/policy.yaml | C378BD03CEE084DF40AFB9DCDF2A9C93 |
| Open | /ce/ca/aws/iam/root-user-mfa/prod.logic.yaml | A9C93C1E1FDD8AB3C301A075FF169910 |
| Open | /ce/ca/aws/iam/root-user-mfa/test-data.json | FB9550FA93296F834FD234D624FF47E6 |
| Open | /types/CA10__CaAwsUser__c/credReport.extracts.yaml | F6D383D933A0B64268B39ADE7012508C |
| Open | /types/CA10__CaAwsUser__c/object.extracts.yaml | 131CCD980BE5290B2C296CE093A686DC |
Available Commandsโ
repo-manager policies generate FULL /ce/ca/aws/iam/root-user-mfa/prod.logic.yaml
repo-manager policies generate DEBUG /ce/ca/aws/iam/root-user-mfa/prod.logic.yaml
repo-manager policies generate CAPTURE_TEST_DATA /ce/ca/aws/iam/root-user-mfa/prod.logic.yaml
repo-manager policies generate TESTS /ce/ca/aws/iam/root-user-mfa/prod.logic.yaml
# Execute tests
repo-manager policies test /ce/ca/aws/iam/root-user-mfa/prod.logic.yaml
Contentโ
---
inputType: "CA10__CaAwsUser__c"
testData:
- file: test-data.json
importExtracts:
- file: /types/CA10__CaAwsUser__c/credReport.extracts.yaml
- file: /types/CA10__CaAwsUser__c/object.extracts.yaml
conditions:
- status: "INAPPLICABLE"
currentStateMessage: "This policy applies only to root users."
check:
NOT_EQUAL:
left:
EXTRACT: CA10__userName__c
right:
TEXT: "root"
- status: "COMPLIANT"
currentStateMessage: "The root user has MFA enabled."
check:
IS_EQUAL:
left:
EXTRACT: CA10__credReportMfaActive__c
right:
BOOLEAN: true
- status: "COMPLIANT"
currentStateMessage: "The root user does not have console credentials."
check:
NOT_EQUAL:
left:
EXTRACT: CA10__credReportPasswordEnabled__c
right:
BOOLEAN: true
otherwise:
status: "INCOMPLIANT"
currentStateMessage: "The root user does not have MFA enabled."
remediationMessage: "Enable MFA for the root user."