Skip to content

utils: do not report invalid IPv6 ranges as overlap - #37

Open
tllovesxs wants to merge 2 commits into
ZSvirt:mainfrom
tllovesxs:codex/fix-ipv6-overlap-invalid-input
Open

tllovesxs wants to merge 2 commits into
ZSvirt:mainfrom
tllovesxs:codex/fix-ipv6-overlap-invalid-input

Conversation

@tllovesxs

@tllovesxs tllovesxs commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Return false for malformed or reversed IPv6 ranges instead of reporting them as overlapping.
  • Log the offending range values so invalid input is visible to operators.
  • Catch only IllegalArgumentException; unexpected runtime failures are no longer silently swallowed.
  • Add regression coverage for overlap, disjoint ranges, malformed input, and reversed ranges.

Fixes #32.

Test plan

  • git diff --check
  • Added TestIPv6NetworkUtilsEdgeCases.
  • Confirmed the underlying IPv6 library rejects reversed ranges.
  • The helper test passes after the narrowed exception handling.

Copilot AI lite review requested due to automatic review settings September 11, 2026 05:24

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ZSvirt] bug: isIpv6RangeOverlap treats invalid ranges as overlapping

2 participants