CfnNetworkAclEntryPropsMixin

class aws_cdk.mixins_preview.aws_ec2.mixins.CfnNetworkAclEntryPropsMixin(props, *, strategy=None)

Bases: Mixin

Specifies an entry, known as a rule, in a network ACL with a rule number you specify.

Each network ACL has a set of numbered ingress rules and a separate set of numbered egress rules.

To create the network ACL, see AWS::EC2::NetworkAcl .

For information about the protocol value, see Protocol Numbers on the Internet Assigned Numbers Authority (IANA) website.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-networkaclentry.html

CloudformationResource:

AWS::EC2::NetworkAclEntry

Mixin:

true

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.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_ec2 import mixins as ec2_mixins

cfn_network_acl_entry_props_mixin = ec2_mixins.CfnNetworkAclEntryPropsMixin(ec2_mixins.CfnNetworkAclEntryMixinProps(
    cidr_block="cidrBlock",
    egress=False,
    icmp=ec2_mixins.CfnNetworkAclEntryPropsMixin.IcmpProperty(
        code=123,
        type=123
    ),
    ipv6_cidr_block="ipv6CidrBlock",
    network_acl_id="networkAclId",
    port_range=ec2_mixins.CfnNetworkAclEntryPropsMixin.PortRangeProperty(
        from=123,
        to=123
    ),
    protocol=123,
    rule_action="ruleAction",
    rule_number=123
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::EC2::NetworkAclEntry.

Parameters:

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['cidrBlock', 'egress', 'icmp', 'ipv6CidrBlock', 'networkAclId', 'portRange', 'protocol', 'ruleAction', 'ruleNumber']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

IcmpProperty

class CfnNetworkAclEntryPropsMixin.IcmpProperty(*, code=None, type=None)

Bases: object

Describes the ICMP type and code.

Parameters:
  • code (Union[int, float, None]) – The Internet Control Message Protocol (ICMP) code. You can use -1 to specify all ICMP codes for the given ICMP type. Required if you specify 1 (ICMP) for the protocol parameter.

  • type (Union[int, float, None]) – The Internet Control Message Protocol (ICMP) type. You can use -1 to specify all ICMP types. Conditional requirement: Required if you specify 1 (ICMP) for the CreateNetworkAclEntry protocol parameter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-networkaclentry-icmp.html

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.mixins_preview.aws_ec2 import mixins as ec2_mixins

icmp_property = ec2_mixins.CfnNetworkAclEntryPropsMixin.IcmpProperty(
    code=123,
    type=123
)

Attributes

code

The Internet Control Message Protocol (ICMP) code.

You can use -1 to specify all ICMP codes for the given ICMP type. Required if you specify 1 (ICMP) for the protocol parameter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-networkaclentry-icmp.html#cfn-ec2-networkaclentry-icmp-code

type

The Internet Control Message Protocol (ICMP) type.

You can use -1 to specify all ICMP types. Conditional requirement: Required if you specify 1 (ICMP) for the CreateNetworkAclEntry protocol parameter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-networkaclentry-icmp.html#cfn-ec2-networkaclentry-icmp-type

PortRangeProperty

class CfnNetworkAclEntryPropsMixin.PortRangeProperty(*, from_=None, to=None)

Bases: object

Describes a range of ports.

Parameters:
  • from – The first port in the range. Required if you specify 6 (TCP) or 17 (UDP) for the protocol parameter.

  • to (Union[int, float, None]) – The last port in the range. Required if you specify 6 (TCP) or 17 (UDP) for the protocol parameter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-networkaclentry-portrange.html

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.mixins_preview.aws_ec2 import mixins as ec2_mixins

port_range_property = ec2_mixins.CfnNetworkAclEntryPropsMixin.PortRangeProperty(
    from=123,
    to=123
)

Attributes

from_

The first port in the range.

Required if you specify 6 (TCP) or 17 (UDP) for the protocol parameter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-networkaclentry-portrange.html#cfn-ec2-networkaclentry-portrange-from

to

The last port in the range.

Required if you specify 6 (TCP) or 17 (UDP) for the protocol parameter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-networkaclentry-portrange.html#cfn-ec2-networkaclentry-portrange-to