Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Guidance on IDNs / Unicode in spec could be misinterpreted #171

Open
ankurdotb opened this issue Jan 28, 2025 · 1 comment
Open

Guidance on IDNs / Unicode in spec could be misinterpreted #171

ankurdotb opened this issue Jan 28, 2025 · 1 comment

Comments

@ankurdotb
Copy link

ankurdotb commented Jan 28, 2025

Section 4.3. International Domain Names of the current specification states:

[DID-CORE] identifier syntax does not allow Unicode in method name nor method specific identifiers.

Implementers should be cautious when implementing support for DID URLs that rely on domain names or path components that contain Unicode characters.

I can see how the "DID Syntax" section of DID Core could be interpreted as "does not allow Unicode or IDNs", but that's not my interpretation because ABNF for DID Core specifically calls out percent-encoding:

Image

Indeed, to comply with RFC 3986 a lot of internationalized domain names are represented in their percent encoding form under the Internationalizing Domain Names in Applications (IDNA) mechanism. W3C's own page on Multilingual Web Addresses gives the example of JP納豆.例.jp which results with IDNA normalisation to xn--jp-cd2fp15c.xn--fsq.jp.

Suggested solution

Do people agree with my interpretation, i.e., did:webvh and DIDs generally should be allowed for IDNs and Unicode characters BUT pointing them to percent-encoding / IDNA mechanism as guidance on how they should conform with DID Core's DID Syntax?

If yes, maybe I can suggest alternative text for Section 4.3. As it stands, it could be a bit misleading, and that would be a shame for a DID method that's so closely linked to domain names.

If my interpretation is incorrect...

...then this becomes an issue to raise and discuss in DID Core

@ankurdotb ankurdotb changed the title Statement in the specification about Unicode is inaccurate Guidance on IDNs / Unicode in spec could be misinterpreted Jan 28, 2025
@ankurdotb
Copy link
Author

Relevant discussion in DID Core here, where Punycode / percent-encoding is discussed: w3c/did#699 (as it happens, that was in relation to did:web as well)

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

No branches or pull requests

1 participant