Class CfnClientVpnEndpoint

java.lang.Object
software.amazon.jsii.JsiiObject
All Implemented Interfaces:
IConstruct, IDependable, IInspectable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:38.437Z") @Stability(Stable) public class CfnClientVpnEndpoint extends CfnResource implements IInspectable
A CloudFormation AWS::EC2::ClientVpnEndpoint.

Specifies a Client VPN endpoint. A Client VPN endpoint is the resource you create and configure to enable and manage client VPN sessions. It is the destination endpoint at which all client VPN sessions are terminated.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.ec2.*;
 CfnClientVpnEndpoint cfnClientVpnEndpoint = CfnClientVpnEndpoint.Builder.create(this, "MyCfnClientVpnEndpoint")
         .authenticationOptions(List.of(ClientAuthenticationRequestProperty.builder()
                 .type("type")
                 // the properties below are optional
                 .activeDirectory(DirectoryServiceAuthenticationRequestProperty.builder()
                         .directoryId("directoryId")
                         .build())
                 .federatedAuthentication(FederatedAuthenticationRequestProperty.builder()
                         .samlProviderArn("samlProviderArn")
                         // the properties below are optional
                         .selfServiceSamlProviderArn("selfServiceSamlProviderArn")
                         .build())
                 .mutualAuthentication(CertificateAuthenticationRequestProperty.builder()
                         .clientRootCertificateChainArn("clientRootCertificateChainArn")
                         .build())
                 .build()))
         .clientCidrBlock("clientCidrBlock")
         .connectionLogOptions(ConnectionLogOptionsProperty.builder()
                 .enabled(false)
                 // the properties below are optional
                 .cloudwatchLogGroup("cloudwatchLogGroup")
                 .cloudwatchLogStream("cloudwatchLogStream")
                 .build())
         .serverCertificateArn("serverCertificateArn")
         // the properties below are optional
         .clientConnectOptions(ClientConnectOptionsProperty.builder()
                 .enabled(false)
                 // the properties below are optional
                 .lambdaFunctionArn("lambdaFunctionArn")
                 .build())
         .clientLoginBannerOptions(ClientLoginBannerOptionsProperty.builder()
                 .enabled(false)
                 // the properties below are optional
                 .bannerText("bannerText")
                 .build())
         .description("description")
         .dnsServers(List.of("dnsServers"))
         .securityGroupIds(List.of("securityGroupIds"))
         .selfServicePortal("selfServicePortal")
         .sessionTimeoutHours(123)
         .splitTunnel(false)
         .tagSpecifications(List.of(TagSpecificationProperty.builder()
                 .resourceType("resourceType")
                 .tags(List.of(CfnTag.builder()
                         .key("key")
                         .value("value")
                         .build()))
                 .build()))
         .transportProtocol("transportProtocol")
         .vpcId("vpcId")
         .vpnPort(123)
         .build();
 
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnClientVpnEndpoint

      protected CfnClientVpnEndpoint(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnClientVpnEndpoint

      protected CfnClientVpnEndpoint(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnClientVpnEndpoint

      @Stability(Stable) public CfnClientVpnEndpoint(@NotNull Construct scope, @NotNull String id, @NotNull CfnClientVpnEndpointProps props)
      Create a new AWS::EC2::ClientVpnEndpoint.

      Parameters:
      scope -
      • scope in which this resource is defined.
      This parameter is required.
      id -
      • scoped id of the resource.
      This parameter is required.
      props -
      • resource properties.
      This parameter is required.
  • Method Details

    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector -
      • tree inspector to collect and process attributes.
      This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getAuthenticationOptions

      @Stability(Stable) @NotNull public Object getAuthenticationOptions()
      Information about the authentication method to be used to authenticate clients.
    • setAuthenticationOptions

      @Stability(Stable) public void setAuthenticationOptions(@NotNull IResolvable value)
      Information about the authentication method to be used to authenticate clients.
    • setAuthenticationOptions

      @Stability(Stable) public void setAuthenticationOptions(@NotNull List<Object> value)
      Information about the authentication method to be used to authenticate clients.
    • getClientCidrBlock

      @Stability(Stable) @NotNull public String getClientCidrBlock()
      The IPv4 address range, in CIDR notation, from which to assign client IP addresses.

      The address range cannot overlap with the local CIDR of the VPC in which the associated subnet is located, or the routes that you add manually. The address range cannot be changed after the Client VPN endpoint has been created. Client CIDR range must have a size of at least /22 and must not be greater than /12.

    • setClientCidrBlock

      @Stability(Stable) public void setClientCidrBlock(@NotNull String value)
      The IPv4 address range, in CIDR notation, from which to assign client IP addresses.

      The address range cannot overlap with the local CIDR of the VPC in which the associated subnet is located, or the routes that you add manually. The address range cannot be changed after the Client VPN endpoint has been created. Client CIDR range must have a size of at least /22 and must not be greater than /12.

    • getConnectionLogOptions

      @Stability(Stable) @NotNull public Object getConnectionLogOptions()
      Information about the client connection logging options.

      If you enable client connection logging, data about client connections is sent to a Cloudwatch Logs log stream. The following information is logged:

      • Client connection requests
      • Client connection results (successful and unsuccessful)
      • Reasons for unsuccessful client connection requests
      • Client connection termination time
    • setConnectionLogOptions

      @Stability(Stable) public void setConnectionLogOptions(@NotNull IResolvable value)
      Information about the client connection logging options.

      If you enable client connection logging, data about client connections is sent to a Cloudwatch Logs log stream. The following information is logged:

      • Client connection requests
      • Client connection results (successful and unsuccessful)
      • Reasons for unsuccessful client connection requests
      • Client connection termination time
    • setConnectionLogOptions

      @Stability(Stable) public void setConnectionLogOptions(@NotNull CfnClientVpnEndpoint.ConnectionLogOptionsProperty value)
      Information about the client connection logging options.

      If you enable client connection logging, data about client connections is sent to a Cloudwatch Logs log stream. The following information is logged:

      • Client connection requests
      • Client connection results (successful and unsuccessful)
      • Reasons for unsuccessful client connection requests
      • Client connection termination time
    • getServerCertificateArn

      @Stability(Stable) @NotNull public String getServerCertificateArn()
      The ARN of the server certificate.

      For more information, see the AWS Certificate Manager User Guide .

    • setServerCertificateArn

      @Stability(Stable) public void setServerCertificateArn(@NotNull String value)
      The ARN of the server certificate.

      For more information, see the AWS Certificate Manager User Guide .

    • getClientConnectOptions

      @Stability(Stable) @Nullable public Object getClientConnectOptions()
      The options for managing connection authorization for new client connections.
    • setClientConnectOptions

      @Stability(Stable) public void setClientConnectOptions(@Nullable IResolvable value)
      The options for managing connection authorization for new client connections.
    • setClientConnectOptions

      @Stability(Stable) public void setClientConnectOptions(@Nullable CfnClientVpnEndpoint.ClientConnectOptionsProperty value)
      The options for managing connection authorization for new client connections.
    • getClientLoginBannerOptions

      @Stability(Stable) @Nullable public Object getClientLoginBannerOptions()
      Options for enabling a customizable text banner that will be displayed on AWS provided clients when a VPN session is established.
    • setClientLoginBannerOptions

      @Stability(Stable) public void setClientLoginBannerOptions(@Nullable IResolvable value)
      Options for enabling a customizable text banner that will be displayed on AWS provided clients when a VPN session is established.
    • setClientLoginBannerOptions

      @Stability(Stable) public void setClientLoginBannerOptions(@Nullable CfnClientVpnEndpoint.ClientLoginBannerOptionsProperty value)
      Options for enabling a customizable text banner that will be displayed on AWS provided clients when a VPN session is established.
    • getDescription

      @Stability(Stable) @Nullable public String getDescription()
      A brief description of the Client VPN endpoint.
    • setDescription

      @Stability(Stable) public void setDescription(@Nullable String value)
      A brief description of the Client VPN endpoint.
    • getDnsServers

      @Stability(Stable) @Nullable public List<String> getDnsServers()
      Information about the DNS servers to be used for DNS resolution.

      A Client VPN endpoint can have up to two DNS servers. If no DNS server is specified, the DNS address configured on the device is used for the DNS server.

    • setDnsServers

      @Stability(Stable) public void setDnsServers(@Nullable List<String> value)
      Information about the DNS servers to be used for DNS resolution.

      A Client VPN endpoint can have up to two DNS servers. If no DNS server is specified, the DNS address configured on the device is used for the DNS server.

    • getSecurityGroupIds

      @Stability(Stable) @Nullable public List<String> getSecurityGroupIds()
      The IDs of one or more security groups to apply to the target network.

      You must also specify the ID of the VPC that contains the security groups.

    • setSecurityGroupIds

      @Stability(Stable) public void setSecurityGroupIds(@Nullable List<String> value)
      The IDs of one or more security groups to apply to the target network.

      You must also specify the ID of the VPC that contains the security groups.

    • getSelfServicePortal

      @Stability(Stable) @Nullable public String getSelfServicePortal()
      Specify whether to enable the self-service portal for the Client VPN endpoint.

      Default Value: enabled

    • setSelfServicePortal

      @Stability(Stable) public void setSelfServicePortal(@Nullable String value)
      Specify whether to enable the self-service portal for the Client VPN endpoint.

      Default Value: enabled

    • getSessionTimeoutHours

      @Stability(Stable) @Nullable public Number getSessionTimeoutHours()
      The maximum VPN session duration time in hours.

      Valid values: 8 | 10 | 12 | 24

      Default value: 24

    • setSessionTimeoutHours

      @Stability(Stable) public void setSessionTimeoutHours(@Nullable Number value)
      The maximum VPN session duration time in hours.

      Valid values: 8 | 10 | 12 | 24

      Default value: 24

    • getSplitTunnel

      @Stability(Stable) @Nullable public Object getSplitTunnel()
      Indicates whether split-tunnel is enabled on the AWS Client VPN endpoint.

      By default, split-tunnel on a VPN endpoint is disabled.

      For information about split-tunnel VPN endpoints, see Split-tunnel AWS Client VPN endpoint in the AWS Client VPN Administrator Guide .

    • setSplitTunnel

      @Stability(Stable) public void setSplitTunnel(@Nullable Boolean value)
      Indicates whether split-tunnel is enabled on the AWS Client VPN endpoint.

      By default, split-tunnel on a VPN endpoint is disabled.

      For information about split-tunnel VPN endpoints, see Split-tunnel AWS Client VPN endpoint in the AWS Client VPN Administrator Guide .

    • setSplitTunnel

      @Stability(Stable) public void setSplitTunnel(@Nullable IResolvable value)
      Indicates whether split-tunnel is enabled on the AWS Client VPN endpoint.

      By default, split-tunnel on a VPN endpoint is disabled.

      For information about split-tunnel VPN endpoints, see Split-tunnel AWS Client VPN endpoint in the AWS Client VPN Administrator Guide .

    • getTagSpecifications

      @Stability(Stable) @Nullable public Object getTagSpecifications()
      The tags to apply to the Client VPN endpoint during creation.
    • setTagSpecifications

      @Stability(Stable) public void setTagSpecifications(@Nullable IResolvable value)
      The tags to apply to the Client VPN endpoint during creation.
    • setTagSpecifications

      @Stability(Stable) public void setTagSpecifications(@Nullable List<Object> value)
      The tags to apply to the Client VPN endpoint during creation.
    • getTransportProtocol

      @Stability(Stable) @Nullable public String getTransportProtocol()
      The transport protocol to be used by the VPN session.

      Default value: udp

    • setTransportProtocol

      @Stability(Stable) public void setTransportProtocol(@Nullable String value)
      The transport protocol to be used by the VPN session.

      Default value: udp

    • getVpcId

      @Stability(Stable) @Nullable public String getVpcId()
      The ID of the VPC to associate with the Client VPN endpoint.

      If no security group IDs are specified in the request, the default security group for the VPC is applied.

    • setVpcId

      @Stability(Stable) public void setVpcId(@Nullable String value)
      The ID of the VPC to associate with the Client VPN endpoint.

      If no security group IDs are specified in the request, the default security group for the VPC is applied.

    • getVpnPort

      @Stability(Stable) @Nullable public Number getVpnPort()
      The port number to assign to the Client VPN endpoint for TCP and UDP traffic.

      Valid Values: 443 | 1194

      Default Value: 443

    • setVpnPort

      @Stability(Stable) public void setVpnPort(@Nullable Number value)
      The port number to assign to the Client VPN endpoint for TCP and UDP traffic.

      Valid Values: 443 | 1194

      Default Value: 443