Skip to content

enable_workload_identity_provider_outbound_signer async

enable_workload_identity_provider_outbound_signer(
    workload_identity_provider_arn: arnType,
    signer_type: workloadIdentityOutboundSignerTypeType,
    *,
    config_overrides: Optional[AsyncIAMClientConfig] = None,
    signing_delay_in_hours: Optional[workloadIdentitySigningDelayInHoursType] = None,
) -> EnableWorkloadIdentityProviderOutboundSignerResponse

Resumes X.509 signing that was stopped with DisableWorkloadIdentityProviderOutboundSigner.

For an organization-scoped provider, only the organization's management account or a delegated administrator can call this operation.

In each slot, IAM resumes the entry that stopped signing most recently, even if that entry has already become INACTIVE. Each resumed entry returns to IN_TRANSITION and IAM clears its end and expiration times. The entry starts signing after SigningDelayInHours, so its trust material reaches verifiers again first. Other entries keep retiring on their own schedule.

Two rules govern which entries IAM can resume. IAM never resumes an entry that a cancelled rotation stopped before it ever signed, and it does resume an entry that you disabled during its IN_TRANSITION period.

IAM does not recheck the certificate authority when it resumes a signer. Confirm that the certificate authority is still active in Amazon Web Services Private CA before you enable the signer. Otherwise, credentials issued after signing resumes fail.

Parameters:

  • workload_identity_provider_arn (arnType) –

    The Amazon Resource Name (ARN) of the workload identity provider.

  • signer_type (workloadIdentityOutboundSignerTypeType) –

    The credential format to resume. The value must be X509. IAM rejects JWT, because IAM manages the outbound signers for JWT credentials, and you cannot disable, enable or delete them.

  • signing_delay_in_hours (Optional[workloadIdentitySigningDelayInHoursType], default: None ) –

    The number of hours before each resumed signer starts signing.

    Default: 1.

Raises:

  • ConcurrentModificationException –

    The request was rejected because multiple requests to change this object were submitted simultaneously. Wait a few minutes and submit your request again.

  • InvalidInputException –

    The request was rejected because an invalid or out-of-range value was supplied for an input parameter.

  • 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.

Source code in docs_src/capo_iam/_services/async_iam.py
async def enable_workload_identity_provider_outbound_signer(
    self,
    workload_identity_provider_arn: "capo_iam.types.arn_type.arnType",
    signer_type: "capo_iam.types.workload_identity_outbound_signer_type_type.workloadIdentityOutboundSignerTypeType",
    *,
    config_overrides: Optional[AsyncIAMClientConfig] = None,
    signing_delay_in_hours: Optional[
        "capo_iam.types.workload_identity_signing_delay_in_hours_type.workloadIdentitySigningDelayInHoursType"
    ] = None,
) -> "capo_iam.types.enable_workload_identity_provider_outbound_signer_response.EnableWorkloadIdentityProviderOutboundSignerResponse":
    """<p>Resumes X.509 signing that was stopped with <a href="https://docs.aws.amazon.com/IAM/latest/APIReference/API_DisableWorkloadIdentityProviderOutboundSigner.html">DisableWorkloadIdentityProviderOutboundSigner</a>.</p> <p>For an organization-scoped provider, only the organization's management account or a delegated administrator can call this operation.</p> <p>In each slot, IAM resumes the entry that stopped signing most recently, even if that entry has already become <code>INACTIVE</code>. Each resumed entry returns to <code>IN_TRANSITION</code> and IAM clears its end and expiration times. The entry starts signing after <code>SigningDelayInHours</code>, so its trust material reaches verifiers again first. Other entries keep retiring on their own schedule.</p> <p>Two rules govern which entries IAM can resume. IAM never resumes an entry that a cancelled rotation stopped before it ever signed, and it does resume an entry that you disabled during its <code>IN_TRANSITION</code> period.</p> <important> <p>IAM does not recheck the certificate authority when it resumes a signer. Confirm that the certificate authority is still active in Amazon Web Services Private CA before you enable the signer. Otherwise, credentials issued after signing resumes fail.</p> </important>

    Args:
        workload_identity_provider_arn: <p>The Amazon Resource Name (ARN) of the workload identity provider.</p>
        signer_type: <p>The credential format to resume. The value must be <code>X509</code>. IAM rejects <code>JWT</code>, because IAM manages the outbound signers for JWT credentials, and you cannot disable, enable or delete them.</p>
        signing_delay_in_hours: <p>The number of hours before each resumed signer starts signing.</p> <p>Default: 1.</p>

    Raises:
        capo_iam.errors.concurrent_modification_exception.ConcurrentModificationException: <p>The request was rejected because multiple requests to change this object were submitted simultaneously. Wait a few minutes and submit your request again.</p>
        capo_iam.errors.invalid_input_exception.InvalidInputException: <p>The request was rejected because an invalid or out-of-range value was supplied for an input parameter.</p>
        capo_iam.errors.no_such_entity_exception.NoSuchEntityException: <p>The request was rejected because it referenced a resource entity that does not exist. The error message describes the resource.</p>
        capo_iam.errors.service_failure_exception.ServiceFailureException: <p>The request processing has failed because of an unknown error, exception or failure.</p>
        capo_iam.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_iam.types.enable_workload_identity_provider_outbound_signer_request.EnableWorkloadIdentityProviderOutboundSignerRequest]",
    ) -> AsyncOperationResponse[
        "capo_iam.types.enable_workload_identity_provider_outbound_signer_response.EnableWorkloadIdentityProviderOutboundSignerResponse"
    ]:
        import capo_iam._operations.aws_identity_management_v20100508.enable_workload_identity_provider_outbound_signer

        (
            output,
            http_response,
        ) = await capo_iam._operations.aws_identity_management_v20100508.enable_workload_identity_provider_outbound_signer.async_enable_workload_identity_provider_outbound_signer(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging("EnableWorkloadIdentityProviderOutboundSigner"),
    )
    input_: capo_iam.types.enable_workload_identity_provider_outbound_signer_request.EnableWorkloadIdentityProviderOutboundSignerRequest = {
        "workload_identity_provider_arn": workload_identity_provider_arn,
        "signer_type": signer_type,
    }
    if signing_delay_in_hours is not None:
        input_["signing_delay_in_hours"] = signing_delay_in_hours

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output