list_security_control_definitions
¶
list_security_control_definitions(
*,
config_overrides: Optional[SecurityHubClientConfig] = None,
standards_arn: Optional[NonEmptyString] = None,
next_token: Optional[NextToken] = None,
max_results: Optional[MaxResults] = None,
providers: Optional[SecurityControlsProviders] = None,
) -> ListSecurityControlDefinitionsResponse
Lists all of the security controls that apply to a specified standard.
Parameters:
-
standards_arn(Optional[NonEmptyString], default:None) –The Amazon Resource Name (ARN) of the standard that you want to view controls for.
-
next_token(Optional[NextToken], default:None) –Optional pagination parameter.
-
max_results(Optional[MaxResults], default:None) –An optional parameter that limits the total results of the API response to the specified number. If this parameter isn't provided in the request, the results include the first 25 security controls that apply to the specified standard. The results also include a
NextTokenparameter that you can use in a subsequent API call to get the next 25 controls. This repeats until all controls for the standard are returned. -
providers(Optional[SecurityControlsProviders], default:None) –A list of cloud providers to filter the security control definitions by. For example, specify
Azureto return only controls that evaluate Azure resources, orGCPto return only controls that evaluate GCP resources.
Raises:
-
InternalException–Internal server error.
-
InvalidAccessException–The account doesn't have permission to perform this action.
-
InvalidInputException–The request was rejected because you supplied an invalid or out-of-range value for an input parameter.
-
LimitExceededException–The request was rejected because it attempted to create resources beyond the current Amazon Web Services account or throttling limits. The error code describes the limit exceeded.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To list Azure security control definitions The following example lists security control definitions for a specified provider.
>>> client.list_security_control_definitions(providers=['Azure'], max_results=3)
To list GCP security control definitions
The following example lists security control definitions for a specified provider.
>>> client.list_security_control_definitions(providers=['GCP'], max_results=3)
To list security controls that apply to a standard
The following example lists security controls that apply to a specified Security Hub standard.
>>> client.list_security_control_definitions(standards_arn='arn:aws:securityhub:::standards/aws-foundational-security-best-practices/v/1.0.0', next_token='NULL', max_results=3)
Source code in docs_src/capo_securityhub/_services/security_hub.py
7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 | |