CfnVPNConnection
- class aws_cdk.aws_ec2.CfnVPNConnection(scope, id, *, customer_gateway_id, type, enable_acceleration=None, local_ipv4_network_cidr=None, local_ipv6_network_cidr=None, outside_ip_address_type=None, remote_ipv4_network_cidr=None, remote_ipv6_network_cidr=None, static_routes_only=None, tags=None, transit_gateway_id=None, transport_transit_gateway_attachment_id=None, tunnel_inside_ip_version=None, vpn_gateway_id=None, vpn_tunnel_options_specifications=None)
Bases:
CfnResource
Specifies a VPN connection between a virtual private gateway and a VPN customer gateway or a transit gateway and a VPN customer gateway.
To specify a VPN connection between a transit gateway and customer gateway, use the
TransitGatewayId
andCustomerGatewayId
properties.To specify a VPN connection between a virtual private gateway and customer gateway, use the
VpnGatewayId
andCustomerGatewayId
properties.For more information, see AWS Site-to-Site VPN in the AWS Site-to-Site VPN User Guide .
- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-vpnconnection.html
- CloudformationResource:
AWS::EC2::VPNConnection
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 cfn_vPNConnection = ec2.CfnVPNConnection(self, "MyCfnVPNConnection", customer_gateway_id="customerGatewayId", type="type", # the properties below are optional enable_acceleration=False, local_ipv4_network_cidr="localIpv4NetworkCidr", local_ipv6_network_cidr="localIpv6NetworkCidr", outside_ip_address_type="outsideIpAddressType", remote_ipv4_network_cidr="remoteIpv4NetworkCidr", remote_ipv6_network_cidr="remoteIpv6NetworkCidr", static_routes_only=False, tags=[CfnTag( key="key", value="value" )], transit_gateway_id="transitGatewayId", transport_transit_gateway_attachment_id="transportTransitGatewayAttachmentId", tunnel_inside_ip_version="tunnelInsideIpVersion", vpn_gateway_id="vpnGatewayId", vpn_tunnel_options_specifications=[ec2.CfnVPNConnection.VpnTunnelOptionsSpecificationProperty( dpd_timeout_action="dpdTimeoutAction", dpd_timeout_seconds=123, enable_tunnel_lifecycle_control=False, ike_versions=[{ "value": "value" }], log_options=ec2.CfnVPNConnection.VpnTunnelLogOptionsSpecificationProperty( cloudwatch_log_options=ec2.CfnVPNConnection.CloudwatchLogOptionsSpecificationProperty( log_enabled=False, log_group_arn="logGroupArn", log_output_format="logOutputFormat" ) ), phase1_dh_group_numbers=[ec2.CfnVPNConnection.Phase1DHGroupNumbersRequestListValueProperty( value=123 )], phase1_encryption_algorithms=[ec2.CfnVPNConnection.Phase1EncryptionAlgorithmsRequestListValueProperty( value="value" )], phase1_integrity_algorithms=[ec2.CfnVPNConnection.Phase1IntegrityAlgorithmsRequestListValueProperty( value="value" )], phase1_lifetime_seconds=123, phase2_dh_group_numbers=[ec2.CfnVPNConnection.Phase2DHGroupNumbersRequestListValueProperty( value=123 )], phase2_encryption_algorithms=[ec2.CfnVPNConnection.Phase2EncryptionAlgorithmsRequestListValueProperty( value="value" )], phase2_integrity_algorithms=[ec2.CfnVPNConnection.Phase2IntegrityAlgorithmsRequestListValueProperty( value="value" )], phase2_lifetime_seconds=123, pre_shared_key="preSharedKey", rekey_fuzz_percentage=123, rekey_margin_time_seconds=123, replay_window_size=123, startup_action="startupAction", tunnel_inside_cidr="tunnelInsideCidr", tunnel_inside_ipv6_cidr="tunnelInsideIpv6Cidr" )] )
- Parameters:
scope (
Construct
) – Scope in which this resource is defined.id (
str
) – Construct identifier for this resource (unique in its scope).customer_gateway_id (
str
) – The ID of the customer gateway at your end of the VPN connection.type (
str
) – The type of VPN connection.enable_acceleration (
Union
[bool
,IResolvable
,None
]) – Indicate whether to enable acceleration for the VPN connection. Default:false
local_ipv4_network_cidr (
Optional
[str
]) – The IPv4 CIDR on the customer gateway (on-premises) side of the VPN connection. Default:0.0.0.0/0
local_ipv6_network_cidr (
Optional
[str
]) – The IPv6 CIDR on the customer gateway (on-premises) side of the VPN connection. Default:::/0
outside_ip_address_type (
Optional
[str
]) – The type of IPv4 address assigned to the outside interface of the customer gateway device. Valid values:PrivateIpv4
|PublicIpv4
Default:PublicIpv4
remote_ipv4_network_cidr (
Optional
[str
]) – The IPv4 CIDR on the AWS side of the VPN connection. Default:0.0.0.0/0
remote_ipv6_network_cidr (
Optional
[str
]) – The IPv6 CIDR on the AWS side of the VPN connection. Default:::/0
static_routes_only (
Union
[bool
,IResolvable
,None
]) – Indicates whether the VPN connection uses static routes only. Static routes must be used for devices that don’t support BGP. If you are creating a VPN connection for a device that does not support Border Gateway Protocol (BGP), you must specifytrue
.tags (
Optional
[Sequence
[Union
[CfnTag
,Dict
[str
,Any
]]]]) – Any tags assigned to the VPN connection.transit_gateway_id (
Optional
[str
]) – The ID of the transit gateway associated with the VPN connection. You must specify eitherTransitGatewayId
orVpnGatewayId
, but not both.transport_transit_gateway_attachment_id (
Optional
[str
]) – The transit gateway attachment ID to use for the VPN tunnel. Required ifOutsideIpAddressType
is set toPrivateIpv4
.tunnel_inside_ip_version (
Optional
[str
]) – Indicate whether the VPN tunnels process IPv4 or IPv6 traffic. Default:ipv4
vpn_gateway_id (
Optional
[str
]) – The ID of the virtual private gateway at the AWS side of the VPN connection. You must specify eitherTransitGatewayId
orVpnGatewayId
, but not both.vpn_tunnel_options_specifications (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,VpnTunnelOptionsSpecificationProperty
,Dict
[str
,Any
]]],None
]) – The tunnel options for the VPN connection.
Methods
- add_deletion_override(path)
Syntactic sugar for
addOverride(path, undefined)
.- Parameters:
path (
str
) – The path of the value to delete.- Return type:
None
- add_dependency(target)
Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
This can be used for resources across stacks (or nested stack) boundaries and the dependency will automatically be transferred to the relevant scope.
- Parameters:
target (
CfnResource
) –- Return type:
None
- add_depends_on(target)
(deprecated) Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
- Parameters:
target (
CfnResource
) –- Deprecated:
use addDependency
- Stability:
deprecated
- Return type:
None
- add_metadata(key, value)
Add a value to the CloudFormation Resource Metadata.
- Parameters:
key (
str
) –value (
Any
) –
- See:
- Return type:
None
Note that this is a different set of metadata from CDK node metadata; this metadata ends up in the stack template under the resource, whereas CDK node metadata ends up in the Cloud Assembly.
- add_override(path, value)
Adds an override to the synthesized CloudFormation resource.
To add a property override, either use
addPropertyOverride
or prefixpath
with “Properties.” (i.e.Properties.TopicName
).If the override is nested, separate each nested level using a dot (.) in the path parameter. If there is an array as part of the nesting, specify the index in the path.
To include a literal
.
in the property name, prefix with a\
. In most programming languages you will need to write this as"\\."
because the\
itself will need to be escaped.For example:
cfn_resource.add_override("Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes", ["myattribute"]) cfn_resource.add_override("Properties.GlobalSecondaryIndexes.1.ProjectionType", "INCLUDE")
would add the overrides Example:
"Properties": { "GlobalSecondaryIndexes": [ { "Projection": { "NonKeyAttributes": [ "myattribute" ] ... } ... }, { "ProjectionType": "INCLUDE" ... }, ] ... }
The
value
argument toaddOverride
will not be processed or translated in any way. Pass raw JSON values in here with the correct capitalization for CloudFormation. If you pass CDK classes or structs, they will be rendered with lowercased key names, and CloudFormation will reject the template.- Parameters:
path (
str
) –The path of the property, you can use dot notation to override values in complex types. Any intermediate keys will be created as needed.
value (
Any
) –The value. Could be primitive or complex.
- Return type:
None
- add_property_deletion_override(property_path)
Adds an override that deletes the value of a property from the resource definition.
- Parameters:
property_path (
str
) – The path to the property.- Return type:
None
- add_property_override(property_path, value)
Adds an override to a resource property.
Syntactic sugar for
addOverride("Properties.<...>", value)
.- Parameters:
property_path (
str
) – The path of the property.value (
Any
) – The value.
- Return type:
None
- apply_removal_policy(policy=None, *, apply_to_update_replace_policy=None, default=None)
Sets the deletion policy of the resource based on the removal policy specified.
The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you’ve removed it from the CDK application or because you’ve made a change that requires the resource to be replaced.
The resource can be deleted (
RemovalPolicy.DESTROY
), or left in your AWS account for data recovery and cleanup later (RemovalPolicy.RETAIN
). In some cases, a snapshot can be taken of the resource prior to deletion (RemovalPolicy.SNAPSHOT
). A list of resources that support this policy can be found in the following link:- Parameters:
policy (
Optional
[RemovalPolicy
]) –apply_to_update_replace_policy (
Optional
[bool
]) – Apply the same deletion policy to the resource’s “UpdateReplacePolicy”. Default: truedefault (
Optional
[RemovalPolicy
]) – The default policy to apply in case the removal policy is not defined. Default: - Default value is resource specific. To determine the default value for a resource, please consult that specific resource’s documentation.
- See:
- Return type:
None
- get_att(attribute_name, type_hint=None)
Returns a token for an runtime attribute of this resource.
Ideally, use generated attribute accessors (e.g.
resource.arn
), but this can be used for future compatibility in case there is no generated attribute.- Parameters:
attribute_name (
str
) – The name of the attribute.type_hint (
Optional
[ResolutionTypeHint
]) –
- Return type:
- get_metadata(key)
Retrieve a value value from the CloudFormation Resource Metadata.
- Parameters:
key (
str
) –- See:
- Return type:
Any
Note that this is a different set of metadata from CDK node metadata; this metadata ends up in the stack template under the resource, whereas CDK node metadata ends up in the Cloud Assembly.
- inspect(inspector)
Examines the CloudFormation resource and discloses attributes.
- Parameters:
inspector (
TreeInspector
) – tree inspector to collect and process attributes.- Return type:
None
- obtain_dependencies()
Retrieves an array of resources this resource depends on.
This assembles dependencies on resources across stacks (including nested stacks) automatically.
- Return type:
List
[Union
[Stack
,CfnResource
]]
- obtain_resource_dependencies()
Get a shallow copy of dependencies between this resource and other resources in the same stack.
- Return type:
List
[CfnResource
]
- override_logical_id(new_logical_id)
Overrides the auto-generated logical ID with a specific ID.
- Parameters:
new_logical_id (
str
) – The new logical ID to use for this stack element.- Return type:
None
- remove_dependency(target)
Indicates that this resource no longer depends on another resource.
This can be used for resources across stacks (including nested stacks) and the dependency will automatically be removed from the relevant scope.
- Parameters:
target (
CfnResource
) –- Return type:
None
- replace_dependency(target, new_target)
Replaces one dependency with another.
- Parameters:
target (
CfnResource
) – The dependency to replace.new_target (
CfnResource
) – The new dependency to add.
- Return type:
None
- to_string()
Returns a string representation of this construct.
- Return type:
str
- Returns:
a string representation of this resource
Attributes
- CFN_RESOURCE_TYPE_NAME = 'AWS::EC2::VPNConnection'
- attr_vpn_connection_id
The ID of the VPN connection.
- CloudformationAttribute:
VpnConnectionId
- cfn_options
Options for this resource, such as condition, update policy etc.
- cfn_resource_type
AWS resource type.
- creation_stack
return:
the stack trace of the point where this Resource was created from, sourced from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most node +internal+ entries filtered.
- customer_gateway_id
The ID of the customer gateway at your end of the VPN connection.
- enable_acceleration
Indicate whether to enable acceleration for the VPN connection.
- local_ipv4_network_cidr
The IPv4 CIDR on the customer gateway (on-premises) side of the VPN connection.
- local_ipv6_network_cidr
The IPv6 CIDR on the customer gateway (on-premises) side of the VPN connection.
- logical_id
The logical ID for this CloudFormation stack element.
The logical ID of the element is calculated from the path of the resource node in the construct tree.
To override this value, use
overrideLogicalId(newLogicalId)
.- Returns:
the logical ID as a stringified token. This value will only get resolved during synthesis.
- node
The tree node.
- outside_ip_address_type
The type of IPv4 address assigned to the outside interface of the customer gateway device.
- ref
Return a string that will be resolved to a CloudFormation
{ Ref }
for this element.If, by any chance, the intrinsic reference of a resource is not a string, you could coerce it to an IResolvable through
Lazy.any({ produce: resource.ref })
.
- remote_ipv4_network_cidr
The IPv4 CIDR on the AWS side of the VPN connection.
- remote_ipv6_network_cidr
The IPv6 CIDR on the AWS side of the VPN connection.
- stack
The stack in which this element is defined.
CfnElements must be defined within a stack scope (directly or indirectly).
- static_routes_only
Indicates whether the VPN connection uses static routes only.
- tags
Tag Manager which manages the tags for this resource.
- tags_raw
Any tags assigned to the VPN connection.
- transit_gateway_id
The ID of the transit gateway associated with the VPN connection.
- transport_transit_gateway_attachment_id
The transit gateway attachment ID to use for the VPN tunnel.
- tunnel_inside_ip_version
Indicate whether the VPN tunnels process IPv4 or IPv6 traffic.
- type
The type of VPN connection.
- vpn_gateway_id
The ID of the virtual private gateway at the AWS side of the VPN connection.
- vpn_tunnel_options_specifications
The tunnel options for the VPN connection.
Static Methods
- classmethod is_cfn_element(x)
Returns
true
if a construct is a stack element (i.e. part of the synthesized cloudformation template).Uses duck-typing instead of
instanceof
to allow stack elements from different versions of this library to be included in the same stack.- Parameters:
x (
Any
) –- Return type:
bool
- Returns:
The construct as a stack element or undefined if it is not a stack element.
- classmethod is_cfn_resource(x)
Check whether the given object is a CfnResource.
- Parameters:
x (
Any
) –- Return type:
bool
- classmethod is_construct(x)
Checks if
x
is a construct.Use this method instead of
instanceof
to properly detectConstruct
instances, even when the construct library is symlinked.Explanation: in JavaScript, multiple copies of the
constructs
library on disk are seen as independent, completely different libraries. As a consequence, the classConstruct
in each copy of theconstructs
library is seen as a different class, and an instance of one class will not test asinstanceof
the other class.npm install
will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of theconstructs
library can be accidentally installed, andinstanceof
will behave unpredictably. It is safest to avoid usinginstanceof
, and using this type-testing method instead.- Parameters:
x (
Any
) – Any object.- Return type:
bool
- Returns:
true if
x
is an object created from a class which extendsConstruct
.
CloudwatchLogOptionsSpecificationProperty
- class CfnVPNConnection.CloudwatchLogOptionsSpecificationProperty(*, log_enabled=None, log_group_arn=None, log_output_format=None)
Bases:
object
Options for sending VPN tunnel logs to CloudWatch.
- Parameters:
log_enabled (
Union
[bool
,IResolvable
,None
]) – Enable or disable VPN tunnel logging feature. Default value isFalse
. Valid values:True
|False
log_group_arn (
Optional
[str
]) – The Amazon Resource Name (ARN) of the CloudWatch log group to send logs to.log_output_format (
Optional
[str
]) – Set log format. Default format isjson
. Valid values:json
|text
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 cloudwatch_log_options_specification_property = ec2.CfnVPNConnection.CloudwatchLogOptionsSpecificationProperty( log_enabled=False, log_group_arn="logGroupArn", log_output_format="logOutputFormat" )
Attributes
- log_enabled
Enable or disable VPN tunnel logging feature. Default value is
False
.Valid values:
True
|False
- log_group_arn
The Amazon Resource Name (ARN) of the CloudWatch log group to send logs to.
- log_output_format
Set log format. Default format is
json
.Valid values:
json
|text
IKEVersionsRequestListValueProperty
- class CfnVPNConnection.IKEVersionsRequestListValueProperty(*, value=None)
Bases:
object
The IKE version that is permitted for the VPN tunnel.
- Parameters:
value (
Optional
[str
]) – The IKE version.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 i_kEVersions_request_list_value_property = { "value": "value" }
Attributes
Phase1DHGroupNumbersRequestListValueProperty
- class CfnVPNConnection.Phase1DHGroupNumbersRequestListValueProperty(*, value=None)
Bases:
object
Specifies a Diffie-Hellman group number for the VPN tunnel for phase 1 IKE negotiations.
- Parameters:
value (
Union
[int
,float
,None
]) – The Diffie-Hellmann group number.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 phase1_dHGroup_numbers_request_list_value_property = ec2.CfnVPNConnection.Phase1DHGroupNumbersRequestListValueProperty( value=123 )
Attributes
Phase1EncryptionAlgorithmsRequestListValueProperty
- class CfnVPNConnection.Phase1EncryptionAlgorithmsRequestListValueProperty(*, value=None)
Bases:
object
Specifies the encryption algorithm for the VPN tunnel for phase 1 IKE negotiations.
- Parameters:
value (
Optional
[str
]) – The value for the encryption algorithm.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 phase1_encryption_algorithms_request_list_value_property = ec2.CfnVPNConnection.Phase1EncryptionAlgorithmsRequestListValueProperty( value="value" )
Attributes
Phase1IntegrityAlgorithmsRequestListValueProperty
- class CfnVPNConnection.Phase1IntegrityAlgorithmsRequestListValueProperty(*, value=None)
Bases:
object
Specifies the integrity algorithm for the VPN tunnel for phase 1 IKE negotiations.
- Parameters:
value (
Optional
[str
]) – The value for the integrity algorithm.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 phase1_integrity_algorithms_request_list_value_property = ec2.CfnVPNConnection.Phase1IntegrityAlgorithmsRequestListValueProperty( value="value" )
Attributes
Phase2DHGroupNumbersRequestListValueProperty
- class CfnVPNConnection.Phase2DHGroupNumbersRequestListValueProperty(*, value=None)
Bases:
object
Specifies a Diffie-Hellman group number for the VPN tunnel for phase 2 IKE negotiations.
- Parameters:
value (
Union
[int
,float
,None
]) – The Diffie-Hellmann group number.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 phase2_dHGroup_numbers_request_list_value_property = ec2.CfnVPNConnection.Phase2DHGroupNumbersRequestListValueProperty( value=123 )
Attributes
Phase2EncryptionAlgorithmsRequestListValueProperty
- class CfnVPNConnection.Phase2EncryptionAlgorithmsRequestListValueProperty(*, value=None)
Bases:
object
Specifies the encryption algorithm for the VPN tunnel for phase 2 IKE negotiations.
- Parameters:
value (
Optional
[str
]) – The encryption algorithm.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 phase2_encryption_algorithms_request_list_value_property = ec2.CfnVPNConnection.Phase2EncryptionAlgorithmsRequestListValueProperty( value="value" )
Attributes
Phase2IntegrityAlgorithmsRequestListValueProperty
- class CfnVPNConnection.Phase2IntegrityAlgorithmsRequestListValueProperty(*, value=None)
Bases:
object
Specifies the integrity algorithm for the VPN tunnel for phase 2 IKE negotiations.
- Parameters:
value (
Optional
[str
]) – The integrity algorithm.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 phase2_integrity_algorithms_request_list_value_property = ec2.CfnVPNConnection.Phase2IntegrityAlgorithmsRequestListValueProperty( value="value" )
Attributes
VpnTunnelLogOptionsSpecificationProperty
- class CfnVPNConnection.VpnTunnelLogOptionsSpecificationProperty(*, cloudwatch_log_options=None)
Bases:
object
Options for logging VPN tunnel activity.
- Parameters:
cloudwatch_log_options (
Union
[IResolvable
,CloudwatchLogOptionsSpecificationProperty
,Dict
[str
,Any
],None
]) – Options for sending VPN tunnel logs to CloudWatch.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 vpn_tunnel_log_options_specification_property = ec2.CfnVPNConnection.VpnTunnelLogOptionsSpecificationProperty( cloudwatch_log_options=ec2.CfnVPNConnection.CloudwatchLogOptionsSpecificationProperty( log_enabled=False, log_group_arn="logGroupArn", log_output_format="logOutputFormat" ) )
Attributes
- cloudwatch_log_options
Options for sending VPN tunnel logs to CloudWatch.
VpnTunnelOptionsSpecificationProperty
- class CfnVPNConnection.VpnTunnelOptionsSpecificationProperty(*, dpd_timeout_action=None, dpd_timeout_seconds=None, enable_tunnel_lifecycle_control=None, ike_versions=None, log_options=None, phase1_dh_group_numbers=None, phase1_encryption_algorithms=None, phase1_integrity_algorithms=None, phase1_lifetime_seconds=None, phase2_dh_group_numbers=None, phase2_encryption_algorithms=None, phase2_integrity_algorithms=None, phase2_lifetime_seconds=None, pre_shared_key=None, rekey_fuzz_percentage=None, rekey_margin_time_seconds=None, replay_window_size=None, startup_action=None, tunnel_inside_cidr=None, tunnel_inside_ipv6_cidr=None)
Bases:
object
The tunnel options for a single VPN tunnel.
- Parameters:
dpd_timeout_action (
Optional
[str
]) – The action to take after DPD timeout occurs. Specifyrestart
to restart the IKE initiation. Specifyclear
to end the IKE session. Valid Values:clear
|none
|restart
Default:clear
dpd_timeout_seconds (
Union
[int
,float
,None
]) – The number of seconds after which a DPD timeout occurs. Constraints: A value greater than or equal to 30. Default:30
enable_tunnel_lifecycle_control (
Union
[bool
,IResolvable
,None
]) – Turn on or off tunnel endpoint lifecycle control feature.ike_versions (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,IKEVersionsRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – The IKE versions that are permitted for the VPN tunnel. Valid values:ikev1
|ikev2
log_options (
Union
[IResolvable
,VpnTunnelLogOptionsSpecificationProperty
,Dict
[str
,Any
],None
]) – Options for logging VPN tunnel activity.phase1_dh_group_numbers (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,Phase1DHGroupNumbersRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – One or more Diffie-Hellman group numbers that are permitted for the VPN tunnel for phase 1 IKE negotiations. Valid values:2
|14
|15
|16
|17
|18
|19
|20
|21
|22
|23
|24
phase1_encryption_algorithms (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,Phase1EncryptionAlgorithmsRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – One or more encryption algorithms that are permitted for the VPN tunnel for phase 1 IKE negotiations. Valid values:AES128
|AES256
|AES128-GCM-16
|AES256-GCM-16
phase1_integrity_algorithms (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,Phase1IntegrityAlgorithmsRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – One or more integrity algorithms that are permitted for the VPN tunnel for phase 1 IKE negotiations. Valid values:SHA1
|SHA2-256
|SHA2-384
|SHA2-512
phase1_lifetime_seconds (
Union
[int
,float
,None
]) – The lifetime for phase 1 of the IKE negotiation, in seconds. Constraints: A value between 900 and 28,800. Default:28800
phase2_dh_group_numbers (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,Phase2DHGroupNumbersRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – One or more Diffie-Hellman group numbers that are permitted for the VPN tunnel for phase 2 IKE negotiations. Valid values:2
|5
|14
|15
|16
|17
|18
|19
|20
|21
|22
|23
|24
phase2_encryption_algorithms (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,Phase2EncryptionAlgorithmsRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – One or more encryption algorithms that are permitted for the VPN tunnel for phase 2 IKE negotiations. Valid values:AES128
|AES256
|AES128-GCM-16
|AES256-GCM-16
phase2_integrity_algorithms (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,Phase2IntegrityAlgorithmsRequestListValueProperty
,Dict
[str
,Any
]]],None
]) – One or more integrity algorithms that are permitted for the VPN tunnel for phase 2 IKE negotiations. Valid values:SHA1
|SHA2-256
|SHA2-384
|SHA2-512
phase2_lifetime_seconds (
Union
[int
,float
,None
]) – The lifetime for phase 2 of the IKE negotiation, in seconds. Constraints: A value between 900 and 3,600. The value must be less than the value forPhase1LifetimeSeconds
. Default:3600
pre_shared_key (
Optional
[str
]) – The pre-shared key (PSK) to establish initial authentication between the virtual private gateway and customer gateway. Constraints: Allowed characters are alphanumeric characters, periods (.), and underscores (_). Must be between 8 and 64 characters in length and cannot start with zero (0).rekey_fuzz_percentage (
Union
[int
,float
,None
]) – The percentage of the rekey window (determined byRekeyMarginTimeSeconds
) during which the rekey time is randomly selected. Constraints: A value between 0 and 100. Default:100
rekey_margin_time_seconds (
Union
[int
,float
,None
]) – The margin time, in seconds, before the phase 2 lifetime expires, during which the AWS side of the VPN connection performs an IKE rekey. The exact time of the rekey is randomly selected based on the value forRekeyFuzzPercentage
. Constraints: A value between 60 and half ofPhase2LifetimeSeconds
. Default:270
replay_window_size (
Union
[int
,float
,None
]) – The number of packets in an IKE replay window. Constraints: A value between 64 and 2048. Default:1024
startup_action (
Optional
[str
]) – The action to take when the establishing the tunnel for the VPN connection. By default, your customer gateway device must initiate the IKE negotiation and bring up the tunnel. Specifystart
for AWS to initiate the IKE negotiation. Valid Values:add
|start
Default:add
tunnel_inside_cidr (
Optional
[str
]) – The range of inside IP addresses for the tunnel. Any specified CIDR blocks must be unique across all VPN connections that use the same virtual private gateway. Constraints: A size /30 CIDR block from the169.254.0.0/16
range. The following CIDR blocks are reserved and cannot be used: -169.254.0.0/30
-169.254.1.0/30
-169.254.2.0/30
-169.254.3.0/30
-169.254.4.0/30
-169.254.5.0/30
-169.254.169.252/30
tunnel_inside_ipv6_cidr (
Optional
[str
]) – The range of inside IPv6 addresses for the tunnel. Any specified CIDR blocks must be unique across all VPN connections that use the same transit gateway. Constraints: A size /126 CIDR block from the localfd00::/8
range.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ec2 as ec2 vpn_tunnel_options_specification_property = ec2.CfnVPNConnection.VpnTunnelOptionsSpecificationProperty( dpd_timeout_action="dpdTimeoutAction", dpd_timeout_seconds=123, enable_tunnel_lifecycle_control=False, ike_versions=[{ "value": "value" }], log_options=ec2.CfnVPNConnection.VpnTunnelLogOptionsSpecificationProperty( cloudwatch_log_options=ec2.CfnVPNConnection.CloudwatchLogOptionsSpecificationProperty( log_enabled=False, log_group_arn="logGroupArn", log_output_format="logOutputFormat" ) ), phase1_dh_group_numbers=[ec2.CfnVPNConnection.Phase1DHGroupNumbersRequestListValueProperty( value=123 )], phase1_encryption_algorithms=[ec2.CfnVPNConnection.Phase1EncryptionAlgorithmsRequestListValueProperty( value="value" )], phase1_integrity_algorithms=[ec2.CfnVPNConnection.Phase1IntegrityAlgorithmsRequestListValueProperty( value="value" )], phase1_lifetime_seconds=123, phase2_dh_group_numbers=[ec2.CfnVPNConnection.Phase2DHGroupNumbersRequestListValueProperty( value=123 )], phase2_encryption_algorithms=[ec2.CfnVPNConnection.Phase2EncryptionAlgorithmsRequestListValueProperty( value="value" )], phase2_integrity_algorithms=[ec2.CfnVPNConnection.Phase2IntegrityAlgorithmsRequestListValueProperty( value="value" )], phase2_lifetime_seconds=123, pre_shared_key="preSharedKey", rekey_fuzz_percentage=123, rekey_margin_time_seconds=123, replay_window_size=123, startup_action="startupAction", tunnel_inside_cidr="tunnelInsideCidr", tunnel_inside_ipv6_cidr="tunnelInsideIpv6Cidr" )
Attributes
- dpd_timeout_action
The action to take after DPD timeout occurs.
Specify
restart
to restart the IKE initiation. Specifyclear
to end the IKE session.Valid Values:
clear
|none
|restart
Default:
clear
- dpd_timeout_seconds
The number of seconds after which a DPD timeout occurs.
Constraints: A value greater than or equal to 30.
Default:
30
- enable_tunnel_lifecycle_control
Turn on or off tunnel endpoint lifecycle control feature.
- ike_versions
The IKE versions that are permitted for the VPN tunnel.
Valid values:
ikev1
|ikev2
- log_options
Options for logging VPN tunnel activity.
- phase1_dh_group_numbers
One or more Diffie-Hellman group numbers that are permitted for the VPN tunnel for phase 1 IKE negotiations.
Valid values:
2
|14
|15
|16
|17
|18
|19
|20
|21
|22
|23
|24
- phase1_encryption_algorithms
One or more encryption algorithms that are permitted for the VPN tunnel for phase 1 IKE negotiations.
Valid values:
AES128
|AES256
|AES128-GCM-16
|AES256-GCM-16
- phase1_integrity_algorithms
One or more integrity algorithms that are permitted for the VPN tunnel for phase 1 IKE negotiations.
Valid values:
SHA1
|SHA2-256
|SHA2-384
|SHA2-512
- phase1_lifetime_seconds
The lifetime for phase 1 of the IKE negotiation, in seconds.
Constraints: A value between 900 and 28,800.
Default:
28800
- phase2_dh_group_numbers
One or more Diffie-Hellman group numbers that are permitted for the VPN tunnel for phase 2 IKE negotiations.
Valid values:
2
|5
|14
|15
|16
|17
|18
|19
|20
|21
|22
|23
|24
- phase2_encryption_algorithms
One or more encryption algorithms that are permitted for the VPN tunnel for phase 2 IKE negotiations.
Valid values:
AES128
|AES256
|AES128-GCM-16
|AES256-GCM-16
- phase2_integrity_algorithms
One or more integrity algorithms that are permitted for the VPN tunnel for phase 2 IKE negotiations.
Valid values:
SHA1
|SHA2-256
|SHA2-384
|SHA2-512
- phase2_lifetime_seconds
The lifetime for phase 2 of the IKE negotiation, in seconds.
Constraints: A value between 900 and 3,600. The value must be less than the value for
Phase1LifetimeSeconds
.Default:
3600
The pre-shared key (PSK) to establish initial authentication between the virtual private gateway and customer gateway.
Constraints: Allowed characters are alphanumeric characters, periods (.), and underscores (_). Must be between 8 and 64 characters in length and cannot start with zero (0).
- rekey_fuzz_percentage
The percentage of the rekey window (determined by
RekeyMarginTimeSeconds
) during which the rekey time is randomly selected.Constraints: A value between 0 and 100.
Default:
100
- rekey_margin_time_seconds
The margin time, in seconds, before the phase 2 lifetime expires, during which the AWS side of the VPN connection performs an IKE rekey.
The exact time of the rekey is randomly selected based on the value for
RekeyFuzzPercentage
.Constraints: A value between 60 and half of
Phase2LifetimeSeconds
.Default:
270
- replay_window_size
The number of packets in an IKE replay window.
Constraints: A value between 64 and 2048.
Default:
1024
- startup_action
The action to take when the establishing the tunnel for the VPN connection.
By default, your customer gateway device must initiate the IKE negotiation and bring up the tunnel. Specify
start
for AWS to initiate the IKE negotiation.Valid Values:
add
|start
Default:
add
- tunnel_inside_cidr
The range of inside IP addresses for the tunnel.
Any specified CIDR blocks must be unique across all VPN connections that use the same virtual private gateway.
Constraints: A size /30 CIDR block from the
169.254.0.0/16
range. The following CIDR blocks are reserved and cannot be used:169.254.0.0/30
169.254.1.0/30
169.254.2.0/30
169.254.3.0/30
169.254.4.0/30
169.254.5.0/30
169.254.169.252/30
- tunnel_inside_ipv6_cidr
The range of inside IPv6 addresses for the tunnel.
Any specified CIDR blocks must be unique across all VPN connections that use the same transit gateway.
Constraints: A size /126 CIDR block from the local
fd00::/8
range.