Loading...
Searching...
No Matches
urlparser::idna Namespace Reference

IDNA (Internationalized Domain Names in Applications) support. More...

Detailed Description

IDNA (Internationalized Domain Names in Applications) support.

liburlparser's own host parsing is ASCII-only per RFC 3986: a Unicode hostname like "café.com" is accepted (it will not throw), but it is kept verbatim rather than normalized, so it will not compare equal to its canonical ASCII/Punycode form "xn--caf-dma.com" even though they are the same domain. This namespace closes that gap with a standalone, dependency- free implementation of per-label Punycode encoding (RFC 3492) - the same public algorithm ada-url/ada and every other IDNA implementation use, but implemented here from scratch rather than linked against ada. See the "IDNA" section of urlparser.cpp for the scope/limits of this implementation (it covers well-formed, already-composed UTF-8 input - the common case - but does not implement the full UTS-46 case-folding/ normalization pipeline).