create_control
¶
create_control(
environment_arn: EnvironmentArn,
framework: FrameworkName,
framework_version: FrameworkVersion,
control_id: ControlID,
parent_control_id: ControlID,
title: ControlTitle,
*,
config_overrides: Optional[AssuranceClientConfig] = None,
description: Optional[ControlDescription] = None,
requirements: Optional[RequirementList] = None,
display_order: Optional[DisplayOrder] = None,
control_intents: Optional[ControlIntentList] = None,
workflow_type: Optional[WorkflowType] = None,
) -> CreateControlOutput
Creates a leaf control, which is a control with no child controls, in a custom framework.
Parameters:
-
environment_arn(EnvironmentArn) –The ARN of this governance environment.
-
framework(FrameworkName) –The name of the compliance framework.
-
framework_version(FrameworkVersion) –The version of the compliance framework.
-
control_id(ControlID) –The control identifier. Optional. If omitted, the operation applies to the full framework.
-
parent_control_id(ControlID) –The identifier of the parent control group.
-
title(ControlTitle) –The display name for the control.
-
description(Optional[ControlDescription], default:None) –A description of the control.
-
requirements(Optional[RequirementList], default:None) –The individual checks an assessment scores for this control. Assign each one an
idthat findings, assessment results, and remediation tasks reference. -
display_order(Optional[DisplayOrder], default:None) –The ordering key that determines the display sequence within the framework.
-
control_intents(Optional[ControlIntentList], default:None) –The technical control intents that classify how an assessment evaluates this leaf control. Supplying at least one intent makes the control eligible for automated scanning. Leaf controls only.
-
workflow_type(Optional[WorkflowType], default:None) –The optional evaluation workflow type. When omitted and controlIntents are present, the service defaults this to automated-scan. Leaf controls only.
Raises:
-
AccessDeniedException–You do not have sufficient access to perform this action. This error occurs when the request is unauthenticated, or is authenticated but lacks permission to invoke the operation.
-
ConflictException–A conflict occurred (for example, resource already exists).
-
InternalServerException–An internal server error occurred.
-
ResourceNotFoundException–The requested resource was not found.
-
ThrottlingException–The request was throttled.
-
ValidationException–The request failed validation.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Create a control Creates a leaf control in the payments team's custom framework while it is still a draft, with a requirement the payments-prod assessment will score.
>>> client.create_control(environment_arn='arn:aws:assurance:us-east-1:111122223333:environment/a1b2c3d4-5678-90ab-cdef-EXAMPLE11111', framework='payments-pci-dss', framework_version='1.0', control_id='PAY-1.1', parent_control_id='PAY-1', title='Encrypt cardholder data at rest', description='Requires that stored cardholder data is encrypted with a customer-managed key.', requirements=[{'id': 'PAY-1.1-R1', 'description': 'Confirm that storage holding cardholder data has encryption enabled.'}], display_order=1, control_intents=['storageEncryptionConfiguration'], workflow_type='automated-scan')
Source code in docs_src/capo_assurance/_services/assurance.py
941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 | |