Mildly cursed factoid about UNC paths:

- UNC Paths can contain IP addresses such as \\192.168.1.1\share
- IPv6 addresses are supported as well
- IPv6 addresses contain colons
- can't have colons in Windows paths since colons are reserved for drive letters

So Microsoft came up with the the ipv6-literal.net domain that's special-cased by Windows so you can to write IPv6 addresses in UNC paths as 2a0e-3c0--21.ipv6-literal.net without it hitting any resolvers.

@karotte why did they do it like that ​

@tauon I mean, what else could they have done? I agree that the solution is a bit bonkers, but I don't immediately see any other viable solutions that don't conflict with anything else.

They could at least held on to the ipv6-literal.net domain.

@karotte @tauon What else they could have done? Well maybe implement some logic which does not make any use of colons in a path impossible. It would be quite clear in this use case that it can't be meant as a drive name.
@julijane @karotte @tauon They probably missed their chance back when UNC paths were introduced. And now way too much software depends on UNC paths being structured in a particular way, breaking backwards compatibility is an absolute no-go. You have to wait for Microsoft to introduce yet another path type, might even happen within your lifetime.
@julijane @karotte @tauon Colons are also used as a separator for NTFS named streams…
@julijane
But that would break all the legacy programs using `strtok(..., ":")` to separate the driver letter! It's a CON!
@karotte @tauon
@karotte
- changed unc parsing to support ipv6 (perhaps
\\[2a0e-3c0--21]\share?)
- i was going to say use ip6.arpa but those don't seem to require AAAA records that point to the requested ip so that's not an option
- use a different domain that's not ipv6-literal.net that won't ever be resolved (i forget in what circumstances underscores are allowed, but
2a0e-3c0--21._ip6?)
- probably something better that i'm not realising

@karotte @tauon

> They could at least held on to the ipv6-literal.net domain.

They could have used ipv6-literal.arpa and probably even gotten it through IANA, though I don't remember if Microsoft literally ever engaged with the IETF.

(also @tauon you don't need to have DNS records for these domains if you just specify that there are none)

@filmroellchen @karotte @tauon I adree that .arpa would have been the right choice. And they do engage in IETF activities (with very good people at that), so IDK why this went so wrong. What I've seen in other companies is that they design good things there and then management decides not to ship it, maybe that happened here too.
@filmroellchen @karotte @tauon That'd also have spared us RFC6874 and the whole mess of https://datatracker.ietf.org/doc/draft-ietf-6man-zone-ui/
Entering IPv6 Zone Identifiers in User Interfaces

This document describes how the zone identifier of an IPv6 scoped address, defined in the IPv6 Scoped Address Architecture (RFC 4007), should be entered into a user interface. It obsoletes RFC 6874 and updates RFC 4007, RFC 7622 and RFC 8089. Discussion Venue This note is to be removed before publishing as an RFC. Discussion of this document takes place on the 6MAN mailing list ([email protected]), which is archived at https://mailarchive.ietf.org/arch/browse/ipv6/ (https://mailarchive.ietf.org/arch/browse/ipv6/).

IETF Datatracker

@filmroellchen @karotte
@karotte @[email protected]

you don't need to have DNS records for these domains if you just specify that there are nonewhat do you mean?

@tauon @karotte this would be a new .arpa domain, which you can specify to have whatever behavior you want through an RFC or the IANA registration. this is why i wouldn’t go with ip6.arpa since it has defined behavior and requires the various PTR records for rDNS.

@karotte @tauon Huh, I missed the bit where they let it lapse! Domain-parked by GoDaddy, how wonderful.

Presumably that means whoever buys it off them will be the proud owner of a domain that nobody on Windows can resolve.

@karotte @tauon couldn't they just keep using dots?
@kitten @karotte wouldn't it get parsed as a domain? ig they could add square brackets syntax to unc though
@tauon @karotte I mean

wouldn't the same apply to IPv4? and it doesn't seem to be an issue
@tauon @karotte oh but IPv6 has letters...

@kitten @tauon @karotte both of them should be interpreted as an integer, that's all that they are. The dots/colons are just there to make it easier on people.

This works in most browsers FYI, at least for v4 - take your router's IP and slap it in your address bar as an integer instead and it'll navigate to your router.

@kitten @karotte no cause ipv4 can only have numbers and domains have to at least have a letter i think
@karotte @tauon Fixed their unc parser to accept ipv6 addresses.
@karotte @tauon They could've used a different notation, like dot separated.
@Arcaik @karotte it would require changes to unc parsing (if you changed colons in ipv6 to dots, 2 dots could appear next to each other) which is possibly why they decided to do it this way
@karotte @tauon wait, they *don't* control the ipv6-literal.net domain?!?!