Skip to content

get_active_vpn_tunnel_status

get_active_vpn_tunnel_status(
    *,
    config_overrides: Optional[EC2ClientConfig] = None,
    vpn_connection_id: Optional[VpnConnectionId] = None,
    vpn_tunnel_outside_ip_address: Optional[String] = None,
    dry_run: Optional[Boolean] = None,
) -> GetActiveVpnTunnelStatusResult

Returns the currently negotiated security parameters for an active VPN tunnel, including IKE version, DH groups, encryption algorithms, and integrity algorithms.

Parameters:

  • vpn_connection_id (Optional[VpnConnectionId], default: None ) –

    The ID of the VPN connection for which to retrieve the active tunnel status.

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

    The external IP address of the VPN tunnel for which to retrieve the active status.

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

    Checks whether you have the required permissions for the action, without actually making the request.

Raises:

Source code in docs_src/capo_ec2/_services/ec2.py
def get_active_vpn_tunnel_status(
    self,
    *,
    config_overrides: Optional[EC2ClientConfig] = None,
    vpn_connection_id: Optional[
        "capo_ec2.types.vpn_connection_id.VpnConnectionId"
    ] = None,
    vpn_tunnel_outside_ip_address: Optional["capo_ec2.types.string.String"] = None,
    dry_run: Optional["capo_ec2.types.boolean.Boolean"] = None,
) -> "capo_ec2.types.get_active_vpn_tunnel_status_result.GetActiveVpnTunnelStatusResult":
    """<p>Returns the currently negotiated security parameters for an active VPN tunnel, including IKE version, DH groups, encryption algorithms, and integrity algorithms.</p>

    Args:
        vpn_connection_id: <p>The ID of the VPN connection for which to retrieve the active tunnel status.</p>
        vpn_tunnel_outside_ip_address: <p>The external IP address of the VPN tunnel for which to retrieve the active status.</p>
        dry_run: <p>Checks whether you have the required permissions for the action, without actually making the request.</p>

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

    def _handler(
        req: "OperationRequest[capo_ec2.types.get_active_vpn_tunnel_status_request.GetActiveVpnTunnelStatusRequest]",
    ) -> OperationResponse[
        "capo_ec2.types.get_active_vpn_tunnel_status_result.GetActiveVpnTunnelStatusResult"
    ]:
        import capo_ec2._operations.amazon_ec2.get_active_vpn_tunnel_status

        output, http_response = (
            capo_ec2._operations.amazon_ec2.get_active_vpn_tunnel_status.get_active_vpn_tunnel_status(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("GetActiveVpnTunnelStatus")
    )
    input_: capo_ec2.types.get_active_vpn_tunnel_status_request.GetActiveVpnTunnelStatusRequest = {}
    if vpn_connection_id is not None:
        input_["vpn_connection_id"] = vpn_connection_id
    if vpn_tunnel_outside_ip_address is not None:
        input_["vpn_tunnel_outside_ip_address"] = vpn_tunnel_outside_ip_address
    if dry_run is not None:
        input_["dry_run"] = dry_run

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output