Skip to content

wafv2 list-resources-for-web-acl only fetches load balancers by default - this is not documented #5417

@slushysnowman

Description

@slushysnowman

Confirm by changing [ ] to [x] below to ensure that it's a bug:

Describe the bug
I have a web ACL which is tied to an Application Load Balancer and an API Gateway

When using 'list-resources-for-web-acl', without specifying ''--resource-type", I would expect to get ALL resources.

However what I actually get is only load balancers. To get API Gateways I need to specify '--resource-type API_GATEWAY'

SDK version number
aws-cli/2.0.17 Python/3.7.3 Linux/5.4.0-42-generic botocore/2.0.0dev21

Platform/OS/Hardware/Device
What are you running the cli on?
Ubuntu 20.04

To Reproduce (observed behavior)
Steps to reproduce the behavior

1 - Create a regional web-acl
2 - Assign web-acl to an ALB and an API Gateway
3 - aws wafv2 list-resources-for-web-acl --web-acl-arn <ARN_HERE>

You will only get the ARN of the ALB returned

Expected behavior
Preferably the ARNs of all associated resources should be returned if --resource-type is not specified

At minimum, documentation should be adjusted to reflect the fact that ALB is set as default - this is currently not the case - https://awscli.amazonaws.com/v2/documentation/api/latest/reference/wafv2/list-resources-for-web-acl.html

Logs/output
n/a

Additional context
n/a

Metadata

Metadata

Assignees

Labels

documentationThis is a problem with documentation.service-apiThis issue is due to a problem in a service API, not the SDK implementation.wafv2

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions