Skip to content

relativeRef should prefer UTF-8 for percent encoding #201

@aphillips

Description

@aphillips

DID Parameters
https://www.w3.org/TR/did-resolution/#did-parameters

A relative URI reference according to RFC3986 Section 4.2 that identifies a resource at a service endpoint, which is selected from a DID document by using the service parameter. If present, the associated value MUST be an ASCII string and MUST use percent-encoding for certain characters as specified in RFC3986 Section 2.1.

The above requirement doesn't specify a specific character encoding to be used when percent-encoding URI-disallowed characters. Specifying that UTF-8 must be used would help interoperability. If the goal is to allow any octets to be transmitted, this should be made clear.

Note that the text does not say what the "certain characters" are. 3986 2.1 only specifies the percent-encoding mechanism, not what the characters are. A casual reader might assume that only ASCII characters are permitted, with the percent encoding reserved for problem characters like = that are also ASCII.

Note

An example later in the spec shows a relative reference that includes text that non-English users might reasonably
expect to include non-ASCII data.
https://www.w3.org/TR/did-resolution/#example-5

did:example:1234?service=files&relativeRef=%2Fmyresume%2Fdoc%3Fversion%3Dlatest
... where myresume, doc, version, and latest path elements might very reasonably use localized representations

Metadata

Metadata

Assignees

Labels

i18n-needs-resolutionIssue the Internationalization Group has raised and looks for a response on.pr-existsThere is an open PR to address this issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions