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
- Parameters:
scope
-- scope in which this resource is defined.
id
-- scoped id of the resource.
- 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
-
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
-
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
-
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
-
cidrBlock
The IPv4 CIDR range to allow or deny, in CIDR notation (for example, 172.16.0.0/24). Requirement is conditional: You must specify theCidrBlock
orIpv6CidrBlock
property.- Parameters:
cidrBlock
- The IPv4 CIDR range to allow or deny, in CIDR notation (for example, 172.16.0.0/24). Requirement is conditional: You must specify theCidrBlock
orIpv6CidrBlock
property. This parameter is required.- Returns:
this
-
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
-
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
-
icmp
The Internet Control Message Protocol (ICMP) code and type.Requirement is conditional: 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
-
icmp
The Internet Control Message Protocol (ICMP) code and type.Requirement is conditional: 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
-
ipv6CidrBlock
The IPv6 network range to allow or deny, in CIDR notation.Requirement is conditional: You must specify the
CidrBlock
orIpv6CidrBlock
property.- Parameters:
ipv6CidrBlock
- The IPv6 network range to allow or deny, in CIDR notation. This parameter is required.- Returns:
this
-
portRange
The range of port numbers for the UDP/TCP protocol.Conditional 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
-
portRange
@Stability(Stable) public CfnNetworkAclEntry.Builder portRange(CfnNetworkAclEntry.PortRangeProperty portRange) The range of port numbers for the UDP/TCP protocol.Conditional 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
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnNetworkAclEntry>
- Returns:
- a newly built instance of
CfnNetworkAclEntry
.
-