update_signing_certificate
¶
update_signing_certificate(
certificate_id: certificateIdType,
status: statusType,
*,
config_overrides: Optional[IAMClientConfig] = None,
user_name: Optional[existingUserNameType] = None,
) -> None
Changes the status of the specified user signing certificate from active to disabled, or vice versa. This operation can be used to disable an IAM user's signing certificate as part of a certificate rotation work flow.
If the UserName field is not specified, the user name is determined implicitly based on the Amazon Web Services access key ID used to sign the request. This operation works for access keys under the Amazon Web Services account. Consequently, you can use this operation to manage Amazon Web Services account root user credentials even if the Amazon Web Services account has no associated users.
Parameters:
-
user_name(Optional[existingUserNameType], default:None) –The name of the IAM user the signing certificate belongs to.
This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-
-
certificate_id(certificateIdType) –The ID of the signing certificate you want to update.
This parameter allows (through its regex pattern) a string of characters that can consist of any upper or lowercased letter or digit.
-
status(statusType) –The status you want to assign to the certificate.
Activemeans that the certificate can be used for programmatic calls to Amazon Web ServicesInactivemeans that the certificate cannot be used.
Raises:
-
InvalidInputException–The request was rejected because an invalid or out-of-range value was supplied for an input parameter.
-
LimitExceededException–The request was rejected because it attempted to create resources beyond the current Amazon Web Services account limits. The error message describes the limit exceeded.
-
NoSuchEntityException–The request was rejected because it referenced a resource entity that does not exist. The error message describes the resource.
-
ServiceFailureException–The request processing has failed because of an unknown error, exception or failure.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To change the active status of a signing certificate for an IAM user The following command changes the status of a signing certificate for a user named Bob to Inactive.
>>> client.update_signing_certificate(user_name='Bob', certificate_id='TA7SMP42TDN5Z26OBPJE7EXAMPLE', status='Inactive')
Source code in docs_src/capo_iam/_services/iam.py
11092 11093 11094 11095 11096 11097 11098 11099 11100 11101 11102 11103 11104 11105 11106 11107 11108 11109 11110 11111 11112 11113 11114 11115 11116 11117 11118 11119 11120 11121 11122 11123 11124 11125 11126 11127 11128 11129 11130 11131 11132 11133 11134 11135 11136 11137 11138 11139 11140 11141 11142 11143 11144 11145 11146 11147 11148 11149 11150 11151 | |