Skip to content

Conversation

@smortex
Copy link
Contributor

@smortex smortex commented Dec 31, 2022

We do not want these addresses to be reported as the default IPv6 address in networking.ip6. Quoting RFC4193:

This document defines an IPv6 unicast address format that is globally
unique and is intended for local communications, usually inside of a
site. These addresses are not expected to be routable on the global
Internet.

This PR also include:

@smortex smortex requested a review from a team as a code owner December 31, 2022 03:02
@puppetlabs-jenkins
Copy link
Collaborator

Can one of the admins verify this patch?

@smortex smortex changed the title Fix filtering of Unique Local Unicast addresses Fix IPv6 unique-local address filtering Dec 31, 2022
@smortex smortex changed the title Fix IPv6 unique-local address filtering Fix IPv6 unique-local unicast address filtering Dec 31, 2022
@smortex smortex changed the title Fix IPv6 unique-local unicast address filtering (FACT-3172) Fix IPv6 unique-local unicast address filtering Dec 31, 2022
@smortex smortex force-pushed the fix-ipv6-unique-local-unicast-address-filtering branch from 64e5107 to 858d0d5 Compare January 3, 2023 19:31
@joshcooper
Copy link
Contributor

@smortex we just merged some changes to address the test failures. If you rebase onto d3447d7 I think your PR will pass

Instead of String comparison, check if IP addresses are included into
the ignored ranges.

No functional change.
RFC4291 define the Link-local unicast range as fe80::/10, not fe80::/16.
As a consequence some Link-local unicast addresses where not correctly
filtered, e.g. fe87::.

While here, add a "working" example with an actual global IPv6 address
from the 2001:0DB8::/32 range reserved for documentation (RFC3849).
We do not want these addresses to be reported as the default IPv6
address in `networking.ip6`.  Quoting RFC4193:

> This document defines an IPv6 unicast address format that is globally
> unique and is intended for local communications, usually inside of a
> site.  These addresses are not expected to be routable on the global
> Internet.
@smortex smortex force-pushed the fix-ipv6-unique-local-unicast-address-filtering branch from 858d0d5 to 40cdf79 Compare January 5, 2023 23:23
Copy link
Contributor

@joshcooper joshcooper left a comment

Choose a reason for hiding this comment

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

Matches https://www.rfc-editor.org/rfc/rfc4193#section-3.2.1:

      Prefix            FC00::/7 prefix to identify Local IPv6 unicast
                        addresses.

@joshcooper joshcooper merged commit 9cb7ef2 into puppetlabs:main Jan 6, 2023
@smortex smortex deleted the fix-ipv6-unique-local-unicast-address-filtering branch January 6, 2023 17:41
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.

3 participants