update_standards_control
async
¶
update_standards_control(
standards_control_arn: NonEmptyString,
*,
config_overrides: Optional[AsyncSecurityHubClientConfig] = None,
control_status: Optional[ControlStatus] = None,
disabled_reason: Optional[NonEmptyString] = None,
) -> UpdateStandardsControlResponse
Used to control whether an individual security standard control is enabled or disabled.
Calls to this operation return a RESOURCE_NOT_FOUND_EXCEPTION error when the standard subscription for the control has StandardsControlsUpdatable value NOT_READY_FOR_UPDATES.
Parameters:
-
standards_control_arn(NonEmptyString) –The ARN of the security standard control to enable or disable.
-
control_status(Optional[ControlStatus], default:None) –The updated status of the security standard control.
-
disabled_reason(Optional[NonEmptyString], default:None) –A description of the reason why you are disabling a security standard control. If you are disabling a control, then this is required.
Raises:
-
AccessDeniedException–You don't have permission to perform the action specified in the request.
-
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.
-
ResourceNotFoundException–The request was rejected because we can't find the specified resource.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To update the enablement status of a standard control The following example disables the specified control in the specified security standard.
>>> await client.update_standards_control(standards_control_arn='arn:aws:securityhub:us-west-1:123456789012:control/pci-dss/v/3.2.1/PCI.AutoScaling.1', control_status='DISABLED', disabled_reason='Not applicable to my service')
Source code in docs_src/capo_securityhub/_services/async_security_hub.py
9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 9174 9175 9176 9177 9178 9179 9180 9181 9182 9183 9184 9185 9186 9187 9188 9189 9190 9191 9192 9193 9194 9195 9196 9197 9198 9199 9200 9201 9202 9203 9204 9205 9206 9207 9208 9209 9210 9211 9212 9213 9214 9215 9216 9217 9218 9219 9220 9221 9222 9223 9224 9225 9226 9227 | |