Skip to main content

EC2 Describe Network Acls

Describes one or more of your network ACLs.

For more information, see Network ACLs in the Amazon Virtual Private Cloud User Guide.

External Documentation

To learn more, visit the AWS documentation.

Basic Parameters

ParameterDescription
AWS Region(s)Enter the desired AWS Region(s).

To execute the action in multiple regions, provide a comma-separated list.
For example: us-east-1,eu-west-2.

If you wish to run the action in all available regions, use the asterisk symbol (*) instead.
Network ACL IDsOne or more network ACL IDs.

Default: Describes all your network ACLs.

Advanced Parameters

ParameterDescription
Disable XML To JSON Auto ConvertWhen checked, XML responses are not automatically converted into JSON format.
Dry RunChecks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.
FiltersOne or more filters.

- association.association-id - The ID of an association ID for the ACL.

- association.network-acl-id - The ID of the network ACL involved in the association.

- association.subnet-id - The ID of the subnet involved in the association.

- default - Indicates whether the ACL is the default network ACL for the VPC.

- entry.cidr - The IPv4 CIDR range specified in the entry.

- entry.icmp.code - The ICMP code specified in the entry, if any.

- entry.icmp.type - The ICMP type specified in the entry, if any.

- entry.ipv6-cidr - The IPv6 CIDR range specified in the entry.

- entry.port-range.from - The start of the port range specified in the entry.

- entry.port-range.to - The end of the port range specified in the entry.

- entry.protocol - The protocol specified in the entry ( tcp | udp | icmp or a protocol number).

- entry.rule-action - Allows or denies the matching traffic ( allow | deny).

- entry.rule-number - The number of an entry (in other words, rule) in the set of ACL entries.

- network-acl-id - The ID of the network ACL.

- owner-id - The ID of the Amazon Web Services account that owns the network ACL.

- tag:<key> - The key/value combination of a tag assigned to the resource. Use the tag key in the filter name and the tag value as the filter value. For example, to find all resources that have a tag with the key Owner and the value TeamA, specify tag:Owner for the filter name and TeamA for the filter value.

- tag-key - The key of a tag assigned to the resource. Use this filter to find all resources assigned a tag with a specific key, regardless of the tag value.

- vpc-id - The ID of the VPC for the network ACL.
Max ResultsThe maximum number of results to return with a single call. To retrieve the remaining results, make another call with the returned nextToken value.
Next TokenThe token for the next page of results.

Example Output

{
"NetworkAcls": [
{
"Associations": [
{
"NetworkAclAssociationId": "aclassoc-66ea5f0b",
"NetworkAclId": "acl-9aeb5ef7",
"SubnetId": "subnet-65ea5f08"
}
],
"Entries": [
{
"CidrBlock": "0.0.0.0/0",
"Egress": true,
"Protocol": "-1",
"RuleAction": "deny",
"RuleNumber": 32767
},
{
"CidrBlock": "0.0.0.0/0",
"Egress": false,
"Protocol": "-1",
"RuleAction": "deny",
"RuleNumber": 32767
}
],
"IsDefault": false,
"NetworkAclId": "acl-5fb85d36",
"Tags": [],
"VpcId": "vpc-a01106c2"
}
]
}

Automation Library Example

Ec2 Describe Network Acls with Aws and Send Results Via Email

Automation LibraryPreview this Automation on desktop