4 ms·
I remember this from work, Windows networking accepts underscores apparently just fine for file shares and I think browsers can access it as well (not sure), bu
by brewmarche 2y ago
I remember this from work, Windows networking accepts underscores apparently just fine for file shares and I think browsers can access it as well (not sure), but Java didn’t want to receive connections under that name because it was illegal.
I think there are multiple RFCs trying to define hostnames and one of them lifted restrictions on digits-only labels because TLDs contain at least one letter so there’d be no confusion with IP addresses. However I was not able to find out who guarantees that there is at least one letter on the TLD level.
- rho138 2y agoDefined in RFC-1123 (Requirements for Internet Hosts - Application and Support) and updated in 5321 (Simple Mail Transfer Protocol) to call out the removal of underscores in hostnames when specifically dealing with SMTP
- criddell 2y agoThe RFC claims underscores are removed to promote interoperability. I suspect that clause harms interoperability more than it helps.
- fanf2 2y agoThe logic is that a large proportion of mail servers will reject messages as specified in that paragraph, so if you want to avoid mysterious delivery failures, your mail software and its configuration should follow suit - better to discover the problem sooner rather than later.
- fanf2 2y agoNote that mail domains are subtly different from hostnames: - fully qualified hostnames can have a trailing dot; mail domains must never have a trailing dot - hostnames can be unqualified (dotless), but RFC 2821 accidentally forbade dotless mail domains so they are even more of an interop minefield than you might expect - NETBIOS hostname conventions (- forbidden, _ allowed) tend to leak into internet hostnames more than mail domains Both are subsets of domain names. I have found it useful to be pedantic about the differences, but I have worked as a postmaster and hostmaster …
- WesolyKubeczek 2y agoIt would still create ambiguities for resolvers that use search zones. Also... there are hexadecimal digits and all kinds of acceptable IP address representations. You can ping 0xbabecafe or visit it in your browser (by specifying the full URL). Now if it was mandatory to use, say, brackets (like we do for email) or something...
- brewmarche 2y agoYes, they forgot to (or chose not to) consider search suffixes here.
- gnfargbl 2y agoIANA manage TLDs. Country-code TLDs are defined as ISO 3166-1 alpha-2 [1] (with the grandfathered exceptions .ac and .uk). Generic TLDs are subjected to a DNS stability check before approval [2] which, amongst other things, requires that they be either made up of characters a-z only or be valid IDNs. [1] https://www.iana.org/help/eligible-tlds https://www.iana.org/help/eligible-tlds [2] https://newgtlds.icann.org/sites/default/files/guidebook-full-04jun12-en.pdf https://newgtlds.icann.org/sites/default/files/guidebook-ful..., section 2.2.1.3.
- brewmarche 2y agoYes ccTLDs are not a problem. But the ICANN rules you linked are even more restrictive, they don’t allow digits at all on the top level (see bottom of page 2-13, unless it’s an IDN) and say it’s due to the referenced RFCs but I don’t see how it follows from them. The seminal definition (must start with a letter) was from RFC 952. Then it was lifted in RFC 1123: “One aspect of host name syntax is hereby changed: the restriction on the first character is relaxed to allow either a letter or a digit. […] If a dotted-decimal number can be entered without such identifying delimiters, then a full syntactic check must be made, because a segment of a host domain name is now allowed to begin with a digit and could legally be entirely numeric (see Section 6.1.2.4 [sic]). However, a valid host name can never have the dotted-decimal form #.#.#.#, since at least the highest-level component label will be alphabetic.” Note that section 6.1.2.4 is completely irrelevant, it looks like a referencing mistake. The later RFC 3696 then calls the rule the LDH rule and says: “There is an additional rule that essentially requires that top-level domain names not be all-numeric.” But it never says where such a rule comes from. RFC 2181 references section 6.1.3.5 of RFC 1123 (maybe that’s an old 6.1.2.4) but it doesn’t state that rule either.
- gumby 2y ago> The seminal definition (must start with a letter) was from RFC 952. Then it was lifted in RFC 1123: “One aspect of host name syntax is hereby changed: the restriction on the first character is relaxed to allow either a letter or a digit. This relaxation was for 3com because you couldn’t very well exclude Bob Metcalf of all people in your networking protocol! I remember there was a bit of chatter at the time about a domain beginning with a digit.