account_audit_configurations
Creates, updates, deletes or gets an account_audit_configuration
resource or lists account_audit_configurations
in a region
Overview
Name | account_audit_configurations |
Type | Resource |
Description | Configures the Device Defender audit settings for this account. Settings include how audit notifications are sent and which audit checks are enabled or disabled. |
Id | aws.iot.account_audit_configurations |
Fields
Name | Datatype | Description |
---|---|---|
account_id | string | Your 12-digit account ID (used as the primary identifier for the CloudFormation resource). |
audit_check_configurations | object | Specifies which audit checks are enabled and disabled for this account. |
audit_notification_target_configurations | object | Information about the targets to which audit notifications are sent. |
role_arn | string | The ARN of the role that grants permission to AWS IoT to access information about your devices, policies, certificates and other items as required when performing an audit. |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | AccountId, AuditCheckConfigurations, RoleArn, region |
delete_resource | DELETE | data__Identifier, region |
update_resource | UPDATE | data__Identifier, data__PatchDocument, region |
list_resources | SELECT | region |
get_resource | SELECT | data__Identifier, region |
SELECT
examples
Gets all account_audit_configurations
in a region.
SELECT
region,
account_id,
audit_check_configurations,
audit_notification_target_configurations,
role_arn
FROM aws.iot.account_audit_configurations
WHERE region = 'us-east-1';
Gets all properties from an individual account_audit_configuration
.
SELECT
region,
account_id,
audit_check_configurations,
audit_notification_target_configurations,
role_arn
FROM aws.iot.account_audit_configurations
WHERE region = 'us-east-1' AND data__Identifier = '<AccountId>';
INSERT
example
Use the following StackQL query and manifest file to create a new account_audit_configuration
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.iot.account_audit_configurations (
AccountId,
AuditCheckConfigurations,
RoleArn,
region
)
SELECT
'{{ AccountId }}',
'{{ AuditCheckConfigurations }}',
'{{ RoleArn }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.iot.account_audit_configurations (
AccountId,
AuditCheckConfigurations,
AuditNotificationTargetConfigurations,
RoleArn,
region
)
SELECT
'{{ AccountId }}',
'{{ AuditCheckConfigurations }}',
'{{ AuditNotificationTargetConfigurations }}',
'{{ RoleArn }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: account_audit_configuration
props:
- name: AccountId
value: '{{ AccountId }}'
- name: AuditCheckConfigurations
value:
AuthenticatedCognitoRoleOverlyPermissiveCheck:
Enabled: '{{ Enabled }}'
CaCertificateExpiringCheck: null
CaCertificateKeyQualityCheck: null
ConflictingClientIdsCheck: null
DeviceCertificateExpiringCheck: null
DeviceCertificateKeyQualityCheck: null
DeviceCertificateSharedCheck: null
IotPolicyOverlyPermissiveCheck: null
IotRoleAliasAllowsAccessToUnusedServicesCheck: null
IotRoleAliasOverlyPermissiveCheck: null
LoggingDisabledCheck: null
RevokedCaCertificateStillActiveCheck: null
RevokedDeviceCertificateStillActiveCheck: null
UnauthenticatedCognitoRoleOverlyPermissiveCheck: null
IntermediateCaRevokedForActiveDeviceCertificatesCheck: null
IoTPolicyPotentialMisConfigurationCheck: null
- name: AuditNotificationTargetConfigurations
value:
Sns:
TargetArn: '{{ TargetArn }}'
RoleArn: '{{ RoleArn }}'
Enabled: '{{ Enabled }}'
- name: RoleArn
value: '{{ RoleArn }}'
DELETE
example
/*+ delete */
DELETE FROM aws.iot.account_audit_configurations
WHERE data__Identifier = '<AccountId>'
AND region = 'us-east-1';
Permissions
To operate on the account_audit_configurations
resource, the following permissions are required:
Create
iot:UpdateAccountAuditConfiguration,
iot:DescribeAccountAuditConfiguration,
iam:PassRole
Read
iot:DescribeAccountAuditConfiguration
Update
iot:UpdateAccountAuditConfiguration,
iot:DescribeAccountAuditConfiguration,
iam:PassRole
Delete
iot:DescribeAccountAuditConfiguration,
iot:DeleteAccountAuditConfiguration
List
iot:DescribeAccountAuditConfiguration