Skip to content

Support IPv6 addresses / CIDRs in the haproxy-ddos-protection-configurator charm #668

Open

Description

@alexdlukens-canonical

Enhancement Proposal

def validate_ip_allow_list(
cls, v: Optional[list[str]]
) -> Optional[list[IPv4Network | IPv4Address]]:
"""Validate and convert IP allow list.
Converts each string to either IPv4Address (for single IPs) or IPv4Network (for CIDR blocks).
Args:
v: The list of IP addresses or CIDR blocks as strings.
Returns:
The list of converted IPv4Address or IPv4Network objects.
"""
if v is None:
return None
return [IPv4Network(ip_str) if "/" in ip_str else IPv4Address(ip_str) for ip_str in v]

Impact

Low (The feature is nice to have)

Impact Rationale

essentially breaks ip-allow-list functionality when ipv6 is enabled on HAProxy - we have no way to control whether remote clients with both an IPv4 and IPv6 address will use their IPv4 address in the request

Activity

  1. syncronize-issues-to-jira commented on Oct 1, 2026

    @syncronize-issues-to-jira

    Thank you for reporting your feedback to us!

    The internal ticket has been created: https://warthogs.atlassian.net/browse/ISD-7057.

    This message was autogenerated

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

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions