[PR #5698] [management] Add IPv6 overlay addressing and capability gating #28380

Open
opened 2026-08-05 08:06:15 -04:00 by saavagebueno · 0 comments
Owner

Original Pull Request: https://github.com/netbirdio/netbird/pull/5698

State: closed
Merged: Yes


Describe your changes

  • Add addrFamily abstraction encapsulating IPv4/IPv6 header offsets, address lengths, set key types, and ICMP protocol numbers
  • Create parallel ip6 netbird table with its own router and ACL manager when the interface has IPv6
  • Route all firewall operations to the correct table by address family
  • Split UpdateSet prefixes by family for dynamic DNS route sets
  • Add IPv6 interval set tests (TestNftablesCreateIpSet_IPv6) and calculateLastIP tests covering both families
  • MSS clamping uses correct overhead per family (40 for v4, 60 for v6)

Stacked on #5706.

Stack

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)

By submitting this pull request, you confirm that you have read and agree to the terms of the Contributor License Agreement.

Documentation

Select exactly one:

  • I added/updated documentation for this change
  • Documentation is not needed for this change (explain why)

Docs PR URL (required if "docs added" is checked)

Paste the PR link from https://github.com/netbirdio/docs here:

https://github.com/netbirdio/docs/pull/667

Summary by CodeRabbit

  • New Features

    • Added broad IPv6 overlay support: account/network settings, per-peer IPv6 addresses, allocation, group-based IPv6 enablement, dual-stack network maps, DNS AAAA records, and IPv6-aware firewall & routing.
  • API / Docs

    • Management API and OpenAPI spec expose IPv6 fields for account settings and peer payloads.
  • Tests

    • Expanded unit/integration tests covering IPv6 allocation, routing, firewall rules, groups, and encoding.
  • Chores

    • Ignored generated testdata directory in VCS.
**Original Pull Request:** https://github.com/netbirdio/netbird/pull/5698 **State:** closed **Merged:** Yes --- ## Describe your changes - Add `addrFamily` abstraction encapsulating IPv4/IPv6 header offsets, address lengths, set key types, and ICMP protocol numbers - Create parallel `ip6 netbird` table with its own router and ACL manager when the interface has IPv6 - Route all firewall operations to the correct table by address family - Split `UpdateSet` prefixes by family for dynamic DNS route sets - Add IPv6 interval set tests (`TestNftablesCreateIpSet_IPv6`) and `calculateLastIP` tests covering both families - MSS clamping uses correct overhead per family (40 for v4, 60 for v6) Stacked on #5706. ## Issue ticket number and link ## Stack - #5631 - #5698 :point_left: ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [x] Is a feature enhancement - [ ] It is a refactor - [x] Created tests that fail without the change (if possible) > By submitting this pull request, you confirm that you have read and agree to the terms of the [Contributor License Agreement](https://github.com/netbirdio/netbird/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT.md). ## Documentation Select exactly one: - [x] I added/updated documentation for this change - [ ] Documentation is **not needed** for this change (explain why) ### Docs PR URL (required if "docs added" is checked) Paste the PR link from https://github.com/netbirdio/docs here: https://github.com/netbirdio/docs/pull/667 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added broad IPv6 overlay support: account/network settings, per-peer IPv6 addresses, allocation, group-based IPv6 enablement, dual-stack network maps, DNS AAAA records, and IPv6-aware firewall & routing. * **API / Docs** * Management API and OpenAPI spec expose IPv6 fields for account settings and peer payloads. * **Tests** * Expanded unit/integration tests covering IPv6 allocation, routing, firewall rules, groups, and encoding. * **Chores** * Ignored generated testdata directory in VCS. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
saavagebueno added the pull-request label 2026-08-05 08:06:15 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#28380