Show / Hide Table of Contents

Class NetworkAclEntryProps

Properties to create NetworkAclEntry.

Inheritance
object
NetworkAclEntryProps
Implements
INetworkAclEntryProps
ICommonNetworkAclEntryOptions
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class NetworkAclEntryProps : INetworkAclEntryProps, ICommonNetworkAclEntryOptions
Syntax (vb)
Public Class NetworkAclEntryProps Implements INetworkAclEntryProps, ICommonNetworkAclEntryOptions
Remarks

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
            // The values are placeholders you should change.
            using Amazon.CDK.AWS.EC2;

            AclCidr aclCidr;
            AclTraffic aclTraffic;
            NetworkAcl networkAcl;

            var networkAclEntryProps = new NetworkAclEntryProps {
                Cidr = aclCidr,
                NetworkAcl = networkAcl,
                RuleNumber = 123,
                Traffic = aclTraffic,

                // the properties below are optional
                Direction = TrafficDirection.EGRESS,
                NetworkAclEntryName = "networkAclEntryName",
                RuleAction = Action.ALLOW
            };

Synopsis

Constructors

NetworkAclEntryProps()

Properties to create NetworkAclEntry.

Properties

Cidr

The CIDR range to allow or deny.

Direction

Traffic direction, with respect to the subnet, this rule applies to.

NetworkAcl

The network ACL this entry applies to.

NetworkAclEntryName

The name of the NetworkAclEntry.

RuleAction

Whether to allow or deny traffic that matches the rule; valid values are "allow" or "deny".

RuleNumber

Rule number to assign to the entry, such as 100.

Traffic

What kind of traffic this ACL rule applies to.

Constructors

NetworkAclEntryProps()

Properties to create NetworkAclEntry.

public NetworkAclEntryProps()
Remarks

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
            // The values are placeholders you should change.
            using Amazon.CDK.AWS.EC2;

            AclCidr aclCidr;
            AclTraffic aclTraffic;
            NetworkAcl networkAcl;

            var networkAclEntryProps = new NetworkAclEntryProps {
                Cidr = aclCidr,
                NetworkAcl = networkAcl,
                RuleNumber = 123,
                Traffic = aclTraffic,

                // the properties below are optional
                Direction = TrafficDirection.EGRESS,
                NetworkAclEntryName = "networkAclEntryName",
                RuleAction = Action.ALLOW
            };

Properties

Cidr

The CIDR range to allow or deny.

public AclCidr Cidr { get; set; }
Property Value

AclCidr

Remarks

ExampleMetadata: fixture=_generated

Direction

Traffic direction, with respect to the subnet, this rule applies to.

public TrafficDirection? Direction { get; set; }
Property Value

TrafficDirection?

Remarks

Default: TrafficDirection.INGRESS

NetworkAcl

The network ACL this entry applies to.

public INetworkAcl NetworkAcl { get; set; }
Property Value

INetworkAcl

Remarks

ExampleMetadata: fixture=_generated

NetworkAclEntryName

The name of the NetworkAclEntry.

public string? NetworkAclEntryName { get; set; }
Property Value

string

Remarks

It is not recommended to use an explicit group name.

Default: If you don't specify a NetworkAclName, AWS CloudFormation generates a unique physical ID and uses that ID for the group name.

RuleAction

Whether to allow or deny traffic that matches the rule; valid values are "allow" or "deny".

public Action? RuleAction { get; set; }
Property Value

Action?

Remarks

Any traffic that is not explicitly allowed is automatically denied in a custom ACL, all traffic is automatically allowed in a default ACL.

Default: ALLOW

RuleNumber

Rule number to assign to the entry, such as 100.

public double RuleNumber { get; set; }
Property Value

double

Remarks

ACL entries are processed in ascending order by rule number. Entries can't use the same rule number unless one is an egress rule and the other is an ingress rule.

Traffic

What kind of traffic this ACL rule applies to.

public AclTraffic Traffic { get; set; }
Property Value

AclTraffic

Remarks

ExampleMetadata: fixture=_generated

Implements

INetworkAclEntryProps
ICommonNetworkAclEntryOptions
Back to top Generated by DocFX