Class CfnNetworkAclEntry.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnNetworkAclEntry>
- Enclosing class:
CfnNetworkAclEntry
CfnNetworkAclEntry
.-
Method Summary
Modifier and TypeMethodDescriptionbuild()
The IPv4 CIDR range to allow or deny, in CIDR notation (for example, 172.16.0.0/24).static CfnNetworkAclEntry.Builder
Whether this rule applies to egress traffic from the subnet (true
) or ingress traffic to the subnet (false
).egress
(IResolvable egress) Whether this rule applies to egress traffic from the subnet (true
) or ingress traffic to the subnet (false
).icmp
(IResolvable icmp) The Internet Control Message Protocol (ICMP) code and type.The Internet Control Message Protocol (ICMP) code and type.ipv6CidrBlock
(String ipv6CidrBlock) The IPv6 network range to allow or deny, in CIDR notation.networkAclId
(String networkAclId) The ID of the ACL for the entry.portRange
(IResolvable portRange) The range of port numbers for the UDP/TCP protocol.portRange
(CfnNetworkAclEntry.PortRangeProperty portRange) The range of port numbers for the UDP/TCP protocol.The IP protocol that the rule applies to.ruleAction
(String ruleAction) Whether to allow or deny traffic that matches the rule;ruleNumber
(Number ruleNumber) Rule number to assign to the entry, such as 100.
-
Method Details
-
create
@Stability(Stable) public static CfnNetworkAclEntry.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.- Returns:
- a new instance of
CfnNetworkAclEntry.Builder
.
-
networkAclId
The ID of the ACL for the entry.- Parameters:
networkAclId
- The ID of the ACL for the entry. This parameter is required.- Returns:
this
- See Also:
-
protocol
The IP protocol that the rule applies to.You must specify -1 or a protocol number. You can specify -1 for all protocols.
If you specify -1, all ports are opened and the
PortRange
property is ignored.- Parameters:
protocol
- The IP protocol that the rule applies to. This parameter is required.- Returns:
this
- See Also:
-
ruleAction
Whether to allow or deny traffic that matches the rule;valid values are "allow" or "deny".
- Parameters:
ruleAction
- Whether to allow or deny traffic that matches the rule;. This parameter is required.- Returns:
this
- See Also:
-
ruleNumber
Rule number to assign to the entry, such as 100.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.
- Parameters:
ruleNumber
- Rule number to assign to the entry, such as 100. This parameter is required.- Returns:
this
- See Also:
-
cidrBlock
The IPv4 CIDR range to allow or deny, in CIDR notation (for example, 172.16.0.0/24). You must specify an IPv4 CIDR block or an IPv6 CIDR block.- Parameters:
cidrBlock
- The IPv4 CIDR range to allow or deny, in CIDR notation (for example, 172.16.0.0/24). You must specify an IPv4 CIDR block or an IPv6 CIDR block. This parameter is required.- Returns:
this
- See Also:
-
egress
Whether this rule applies to egress traffic from the subnet (true
) or ingress traffic to the subnet (false
).By default, AWS CloudFormation specifies
false
.- Parameters:
egress
- Whether this rule applies to egress traffic from the subnet (true
) or ingress traffic to the subnet (false
). This parameter is required.- Returns:
this
- See Also:
-
egress
Whether this rule applies to egress traffic from the subnet (true
) or ingress traffic to the subnet (false
).By default, AWS CloudFormation specifies
false
.- Parameters:
egress
- Whether this rule applies to egress traffic from the subnet (true
) or ingress traffic to the subnet (false
). This parameter is required.- Returns:
this
- See Also:
-
icmp
The Internet Control Message Protocol (ICMP) code and type.Required if specifying 1 (ICMP) for the protocol parameter.
- Parameters:
icmp
- The Internet Control Message Protocol (ICMP) code and type. This parameter is required.- Returns:
this
- See Also:
-
icmp
The Internet Control Message Protocol (ICMP) code and type.Required if specifying 1 (ICMP) for the protocol parameter.
- Parameters:
icmp
- The Internet Control Message Protocol (ICMP) code and type. This parameter is required.- Returns:
this
- See Also:
-
ipv6CidrBlock
The IPv6 network range to allow or deny, in CIDR notation.You must specify an IPv4 CIDR block or an IPv6 CIDR block.
- Parameters:
ipv6CidrBlock
- The IPv6 network range to allow or deny, in CIDR notation. This parameter is required.- Returns:
this
- See Also:
-
portRange
The range of port numbers for the UDP/TCP protocol.Required if specifying 6 (TCP) or 17 (UDP) for the protocol parameter.
- Parameters:
portRange
- The range of port numbers for the UDP/TCP protocol. This parameter is required.- Returns:
this
- See Also:
-
portRange
@Stability(Stable) public CfnNetworkAclEntry.Builder portRange(CfnNetworkAclEntry.PortRangeProperty portRange) The range of port numbers for the UDP/TCP protocol.Required if specifying 6 (TCP) or 17 (UDP) for the protocol parameter.
- Parameters:
portRange
- The range of port numbers for the UDP/TCP protocol. This parameter is required.- Returns:
this
- See Also:
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnNetworkAclEntry>
- Returns:
- a newly built instance of
CfnNetworkAclEntry
.
-