delegated_admins
Creates, updates, deletes or gets a delegated_admin resource or lists delegated_admins in a region
Overview
| Name | delegated_admins |
| Type | Resource |
| Description | The ``AWS::SecurityHub::DelegatedAdmin`` resource designates the delegated ASHlong administrator account for an organization. You must enable the integration between ASH and AOlong before you can designate a delegated ASH administrator. Only the management account for an organization can designate the delegated ASH administrator account. For more information, see [Designating the delegated administrator](https://docs.aws.amazon.com/securityhub/latest/userguide/designate-orgs-admin-account.html#designate-admin-instructions) in the *User Guide*. To change the delegated administrator account, remove the current delegated administrator account, and then designate the new account. To designate multiple delegated administrators in different organizations and AWS-Regions, we recommend using [mappings](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/mappings-section-structure.html). Tags aren't supported for this resource. |
| Id | awscc.securityhub.delegated_admins |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
delegated_admin_identifier | string | |
admin_account_id | string | The AWS-account identifier of the account to designate as the Security Hub administrator account. |
status | string | |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
delegated_admin_identifier | string | |
region | string | AWS region. |
For more information, see AWS::SecurityHub::DelegatedAdmin.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | delegated_admins | INSERT | AdminAccountId, region |
delete_resource | delegated_admins | DELETE | Identifier, region |
list_resources | delegated_admins_list_only | SELECT | region |
get_resource | delegated_admins | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual delegated_admin.
SELECT
region,
delegated_admin_identifier,
admin_account_id,
status
FROM awscc.securityhub.delegated_admins
WHERE
region = 'us-east-1' AND
Identifier = '{{ delegated_admin_identifier }}';
Lists all delegated_admins in a region.
SELECT
region,
delegated_admin_identifier
FROM awscc.securityhub.delegated_admins_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new delegated_admin resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.securityhub.delegated_admins (
AdminAccountId,
region
)
SELECT
'{{ admin_account_id }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.securityhub.delegated_admins (
AdminAccountId,
region
)
SELECT
'{{ admin_account_id }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: delegated_admin
props:
- name: admin_account_id
value: '{{ admin_account_id }}'
DELETE example
/*+ delete */
DELETE FROM awscc.securityhub.delegated_admins
WHERE
Identifier = '{{ delegated_admin_identifier }}' AND
region = 'us-east-1';
Permissions
To operate on the delegated_admins resource, the following permissions are required:
- Create
- Read
- Delete
- List
securityhub:EnableOrganizationAdminAccount,
organizations:DescribeOrganization,
organizations:EnableAWSServiceAccess,
organizations:RegisterDelegatedAdministrator
securityhub:ListOrganizationAdminAccounts,
organizations:DescribeOrganization
securityhub:DisableOrganizationAdminAccount,
organizations:DescribeOrganization
securityhub:ListOrganizationAdminAccounts,
organizations:DescribeOrganization