Imports the certificate revocation list (CRL). A CRL is a list of certificates that have been revoked by the issuing certificate Authority (CA).In order to be properly imported, a CRL must be in PEM format. IAM Roles Anywhere validates against the CRL before issuing credentials.
Required permissions: rolesanywhere:ImportCrl.
Parameters:
-
name
(ResourceName)
–
The name of the certificate revocation list (CRL).
-
crl_data
(bytes)
–
The x509 v3 specified certificate revocation list (CRL).
-
enabled
(Optional[bool], default:
None
)
–
Specifies whether the certificate revocation list (CRL) is enabled.
-
tags
(Optional[TagList], default:
None
)
–
A list of tags to attach to the certificate revocation list (CRL).
-
trust_anchor_arn
(TrustAnchorArn)
–
The ARN of the TrustAnchor the certificate revocation list (CRL) will provide revocation for.
Raises:
Source code in docs_src/capo_rolesanywhere/_services/roles_anywhere.py
| def import_crl(
self,
name: "capo_rolesanywhere.types.resource_name.ResourceName",
crl_data: bytes,
trust_anchor_arn: "capo_rolesanywhere.types.trust_anchor_arn.TrustAnchorArn",
*,
config_overrides: Optional[RolesAnywhereClientConfig] = None,
enabled: Optional[bool] = None,
tags: Optional["capo_rolesanywhere.types.tag_list.TagList"] = None,
) -> "capo_rolesanywhere.types.crl_detail_response.CrlDetailResponse":
"""<p>Imports the certificate revocation list (CRL). A CRL is a list of certificates that have been revoked by the issuing certificate Authority (CA).In order to be properly imported, a CRL must be in PEM format. IAM Roles Anywhere validates against the CRL before issuing credentials. </p> <p> <b>Required permissions: </b> <code>rolesanywhere:ImportCrl</code>. </p>
Args:
name: <p>The name of the certificate revocation list (CRL).</p>
crl_data: <p>The x509 v3 specified certificate revocation list (CRL).</p>
enabled: <p>Specifies whether the certificate revocation list (CRL) is enabled.</p>
tags: <p>A list of tags to attach to the certificate revocation list (CRL).</p>
trust_anchor_arn: <p>The ARN of the TrustAnchor the certificate revocation list (CRL) will provide revocation for.</p>
Raises:
capo_rolesanywhere.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
capo_rolesanywhere.errors.validation_exception.ValidationException: <p>Validation exception error.</p>
capo_rolesanywhere.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_rolesanywhere.types.import_crl_request.ImportCrlRequest]",
) -> OperationResponse[
"capo_rolesanywhere.types.crl_detail_response.CrlDetailResponse"
]:
import capo_rolesanywhere._operations.roles_anywhere.import_crl
output, http_response = (
capo_rolesanywhere._operations.roles_anywhere.import_crl.import_crl(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
def _redact_input(
input_: "capo_rolesanywhere.types.import_crl_request.ImportCrlRequest",
) -> dict[str, Any]:
import capo_rolesanywhere.types.import_crl_request
return capo_rolesanywhere.types.import_crl_request.redact_sensitive(input_)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ImportCrl", redact_input=_redact_input)
)
input_: capo_rolesanywhere.types.import_crl_request.ImportCrlRequest = {
"name": name,
"crl_data": crl_data,
"trust_anchor_arn": trust_anchor_arn,
}
if enabled is not None:
input_["enabled"] = enabled
if tags is not None:
input_["tags"] = tags
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|