Skip to content

[BUG] CreateIPSet validation not working #3328

Description

@ConorWright

Service

WAF v2 (wafv2)

AWS API Action

CreateIPSet (and maybe UpdateIPSet)

Expected behavior

AWS WAFv2 requires each entry in an IPSet's Addresses list to be in CIDR notation (e.g. 203.0.113.10/32). AWS's documentation states this requirement explicitly for CreateIPSet/UpdateIPSet, and it rejects a bare IP address with no CIDR suffix as invalid input.

Actual behavior

Floci accepts a bare IPv4 address with no CIDR suffix and returns a normal 200/success response, identical in shape to a request using proper CIDR notation. No validation error, no warning.

{
    "Summary": {
        "Name": "cidr-validation-test",
        "Id": "0d3a6391-aacf-444c-b8b3-296941d1e720",
        "LockToken": "2d300e29-91ea-4c90-8ecc-08db420f1ad0",
        "ARN": "arn:aws:wafv2:us-east-1:000000000000:regional/ipset/cidr-validation-test/0d3a6391-aacf-444c-b8b3-296941d1e720"
    }
}

Reproduction

export AWS_ENDPOINT_URL=http://localhost:4566
export AWS_ACCESS_KEY_ID=test
export AWS_SECRET_ACCESS_KEY=test
export AWS_DEFAULT_REGION=us-east-1

# Bare IP, no CIDR suffix - AWS should reject, Floci accepts
aws wafv2 create-ip-set \
  --name cidr-validation-test --scope REGIONAL \
  --ip-address-version IPV4 \
  --addresses 203.0.113.10

# For comparison: proper CIDR notation, also succeeds (as expected)
aws wafv2 create-ip-set \
  --name cidr-validation-test-good --scope REGIONAL \
  --ip-address-version IPV4 \
  --addresses 203.0.113.10/32

Environment

  • Floci version / image tag: 2.0.1
  • Java SDK version (if applicable): N/A
  • How you're running Floci: Docker

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingwafv2AWS WAF v2

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions