Skip to content

import_client_vpn_client_certificate_revocation_list async

import_client_vpn_client_certificate_revocation_list(
    *,
    config_overrides: Optional[AsyncEC2ClientConfig] = None,
    client_vpn_endpoint_id: Optional[ClientVpnEndpointId] = None,
    certificate_revocation_list: Optional[String] = None,
    dry_run: Optional[Boolean] = None,
) -> ImportClientVpnClientCertificateRevocationListResult

Uploads a client certificate revocation list to the specified Client VPN endpoint. Uploading a client certificate revocation list overwrites the existing client certificate revocation list.

Uploading a client certificate revocation list resets existing client connections.

Parameters:

  • client_vpn_endpoint_id (Optional[ClientVpnEndpointId], default: None ) –

    The ID of the Client VPN endpoint to which the client certificate revocation list applies.

  • certificate_revocation_list (Optional[String], default: None ) –

    The client certificate revocation list file. For more information, see Generate a Client Certificate Revocation List in the Client VPN Administrator Guide.

  • dry_run (Optional[Boolean], default: None ) –

    Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Raises:

Source code in docs_src/capo_ec2/_services/async_ec2.py
async def import_client_vpn_client_certificate_revocation_list(
    self,
    *,
    config_overrides: Optional[AsyncEC2ClientConfig] = None,
    client_vpn_endpoint_id: Optional[
        "capo_ec2.types.client_vpn_endpoint_id.ClientVpnEndpointId"
    ] = None,
    certificate_revocation_list: Optional["capo_ec2.types.string.String"] = None,
    dry_run: Optional["capo_ec2.types.boolean.Boolean"] = None,
) -> "capo_ec2.types.import_client_vpn_client_certificate_revocation_list_result.ImportClientVpnClientCertificateRevocationListResult":
    """<p>Uploads a client certificate revocation list to the specified Client VPN endpoint. Uploading a client certificate revocation list overwrites the existing client certificate revocation list.</p> <p>Uploading a client certificate revocation list resets existing client connections.</p>

    Args:
        client_vpn_endpoint_id: <p>The ID of the Client VPN endpoint to which the client certificate revocation list applies.</p>
        certificate_revocation_list: <p>The client certificate revocation list file. For more information, see <a href="https://docs.aws.amazon.com/vpn/latest/clientvpn-admin/cvpn-working-certificates.html#cvpn-working-certificates-generate">Generate a Client Certificate Revocation List</a> in the <i>Client VPN Administrator Guide</i>.</p>
        dry_run: <p>Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is <code>DryRunOperation</code>. Otherwise, it is <code>UnauthorizedOperation</code>.</p>

    Raises:
        capo_ec2.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_ec2.types.import_client_vpn_client_certificate_revocation_list_request.ImportClientVpnClientCertificateRevocationListRequest]",
    ) -> AsyncOperationResponse[
        "capo_ec2.types.import_client_vpn_client_certificate_revocation_list_result.ImportClientVpnClientCertificateRevocationListResult"
    ]:
        import capo_ec2._operations.amazon_ec2.import_client_vpn_client_certificate_revocation_list

        (
            output,
            http_response,
        ) = await capo_ec2._operations.amazon_ec2.import_client_vpn_client_certificate_revocation_list.async_import_client_vpn_client_certificate_revocation_list(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging("ImportClientVpnClientCertificateRevocationList"),
    )
    input_: capo_ec2.types.import_client_vpn_client_certificate_revocation_list_request.ImportClientVpnClientCertificateRevocationListRequest = {}
    if client_vpn_endpoint_id is not None:
        input_["client_vpn_endpoint_id"] = client_vpn_endpoint_id
    if certificate_revocation_list is not None:
        input_["certificate_revocation_list"] = certificate_revocation_list
    if dry_run is not None:
        input_["dry_run"] = dry_run

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