product_subscriptions
Creates, updates, deletes or gets a product_subscription resource or lists product_subscriptions in a region
Overview
| Name | product_subscriptions |
| Type | Resource |
| Description | The AWS::SecurityHub::ProductSubscription resource represents a subscription to a service that is allowed to generate findings for your Security Hub account. One product subscription resource is created for each product enabled. |
| Id | awscc.securityhub.product_subscriptions |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
product_arn | string | The generic ARN of the product being subscribed to |
product_subscription_arn | string | The ARN of the product subscription for the account |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
product_subscription_arn | string | The ARN of the product subscription for the account |
region | string | AWS region. |
For more information, see AWS::SecurityHub::ProductSubscription.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | product_subscriptions | INSERT | ProductArn, region |
delete_resource | product_subscriptions | DELETE | Identifier, region |
list_resources | product_subscriptions_list_only | SELECT | region |
get_resource | product_subscriptions | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual product_subscription.
SELECT
region,
product_arn,
product_subscription_arn
FROM awscc.securityhub.product_subscriptions
WHERE
region = 'us-east-1' AND
Identifier = '{{ product_subscription_arn }}';
Lists all product_subscriptions in a region.
SELECT
region,
product_subscription_arn
FROM awscc.securityhub.product_subscriptions_list_only
WHERE
region = 'us-east-1';
INSERT example
Use the following StackQL query and manifest file to create a new product_subscription resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.securityhub.product_subscriptions (
ProductArn,
region
)
SELECT
'{{ product_arn }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.securityhub.product_subscriptions (
ProductArn,
region
)
SELECT
'{{ product_arn }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: product_subscription
props:
- name: product_arn
value: '{{ product_arn }}'
DELETE example
/*+ delete */
DELETE FROM awscc.securityhub.product_subscriptions
WHERE
Identifier = '{{ product_subscription_arn }}' AND
region = 'us-east-1';
Permissions
To operate on the product_subscriptions resource, the following permissions are required:
- Create
- Read
- Delete
- List
securityhub:EnableImportFindingsForProduct
securityhub:ListEnabledProductsForImport
securityhub:ListEnabledProductsForImport,
securityhub:DisableImportFindingsForProduct
securityhub:ListEnabledProductsForImport