5 ms·
> xn--ime-zza.eu > šime.eu Looks like HN needs Punycode support [1] when it displays the domain name after the article title. [1] https://en.wikipedia.org/wi
by crazygringo 3y ago
> xn--ime-zza.eu
> šime.eu
Looks like HN needs Punycode support [1] when it displays the domain name after the article title.
[1] https://en.wikipedia.org/wiki/Punycode https://en.wikipedia.org/wiki/Punycode
- samatman 3y ago> when it displays the domain name That is the domain name. I'm glad that Hacker News, the site for hackers, displays the domain name, and not the rendered display version of the domain name. Other places can and should do it differently, it's the right choice here.
- crazygringo 3y agoBut I can't read the ASCII encoding. It's gibberish. It tells me nothing about which site the article is from. It's unintelligible. You might as well not show anything at all. I can't understand why you think the underlying ASCII encoding should be used, instead of the Unicode domain that actually gets rendered in the browser's address bar. That makes as much sense as saying non-ASCII characters in the comments section should be displayed as raw ASCII bytes instead of correctly interpreted as UTF-8 characters. Or that domains shouldn't even be displayed as letters but just as sequences of numbers that are the code points. The whole point of a domain name is to be semantically meaningful. Otherwise we'd just use IP addresses.
- samatman 3y agoIn the comments, UTF-8 is the encoding, so it makes sense to display it (although you'll notice that some characters are filtered out, emoji most of all). In a domain name, punycode is the encoding. The actual domain name, the one you'd need to run DNS and such, is what you see. Also, rendering it into unicode is a vector for attacks. So it's the wrong choice here, where no one wants to deal with the aggravation of knowing that confusables can be slipped into domain names at any time.
- crazygringo 3y ago> The actual domain name, the one you'd need to run DNS and such, is what you see. But it's not something we should see. It's terrible UX for the reasons I presented. I don't ever want to see the underlying gibberish in a context where I'm reading and commenting on the web. This is a forum for discussing news articles from sites. Gibberish is not what you ever want to see. And the idea of being a vector for attacks doesn't hold water. Yes it's true in a theoretical sense, but anything can be a vector for attacks. If the Unicode version of the domain name is safe enough for major browsers to display in the address bar, then it's safe enough to display to the even more tech-savvy HN readership. (Also your comment seems to misunderstand the analogy between UTF-8 and Punycode. You say "UTF-8 is the encoding, so it makes sense to display it" -- but the point is HN doesn't display it. HN displays Unicode characters, not the underlying UTF-8 bytes. Which is the same way you want to display Unicode characters for a domain name, not the underlying Punycode bytes.)
- samatman 3y ago> your comment seems to misunderstand the analogy You're mistaking misunderstanding for disagreement. We understand each other perfectly well, we simply disagree.
- 911e 3y agoyeah accents on website is not great
- qwery 3y agoWhat does it mean for HN to "support" punycode? That `Apple Vision Pro 2 | xn--80ak6aa92e.com` will appear as `[...] | apple.com`?
- sulam 3y agoLiterally what they said. The site for this post doesn’t display properly.
- walrus01 3y agoOr maybe it's good that HN doesn't support punycode so that you can know immediately that you're visiting an IDN domain name, and people don't try to sneak in submissions with IDF homograph similarities to troll or pretend to be a site that they're not.
- mariusor 3y agoI doubt that a malicious punycode host name would pass muster more than a minute under the scrutiny of the HN crowd.
- walrus01 3y agoIndeed so, but it would be amusing to see someone try. More likely someone would register a $11 throw away .com or .net domain to host a temporary httpd and post as a joke with some hand crafted satire of a new tech product, which has lots of potential.