Re: [web-nfc] Is the external type validate part correct? (#642)

Seems like this should probably be:

> The external type nns percent-encode set is the [C0 control percent-encode set](https://url.spec.whatwg.org/#c0-control-percent-encode-set) and U+0020 SPACE, U+0023 (#), U+003A (:), U+003C (<), U+003E (>), U+003F (?), U+005B ([), U+005C (\), U+005D (]), U+005E (^), U+0060 (`), U+007B ({), U+007C (|), and U+007D (}).

> If input is empty, return false.
> [UTF-8 percent-encode](https://url.spec.whatwg.org/#string-utf-8-percent-encode) input using the the [external type percent-encode set].
> If input length exceeds 255 bytes, return false.
> Let nns be the input from the start of input up to but excluding the last occurrence of U+003A (:), or null if that is not found.
> Let type be the input after the last occurrence, if any, of U+003A (:) up to the end of input, or null if that is not found.
> If nns or type is null, return false.
> If nss starts with U+002F (/), return false.
> If nss contains [C0 control](https://infra.spec.whatwg.org/#c0-control), U+0020 SPACE, U+0023 (#), U+003A (:), U+003C (<), U+003E (>), U+003F (?), U+005B ([), U+005C (\), U+005D (]), U+005E (^), U+0060 (`), U+007B ({), U+007C (|), U+007D (})  or U+007F DELETE, return false
> If type contains [code points](https://infra.spec.whatwg.org/#code-point) that are not [ASCII alphanumeric](https://infra.spec.whatwg.org/#ascii-alphanumeric), or U+0024 ($), U+0027 ('), U+0028 LEFT PARENTHESIS ((), U+0029 RIGHT PARENTHESIS ()), U+002A (*), U+002B (+), U+002C (,), U+002D (-), U+002E (.), U+003B (;), U+003D (=), U+0040 (@), U+005F (_), return false.
> Return true.







-- 
GitHub Notification of comment by kenchris
Please view or discuss this issue at https://github.com/w3c/web-nfc/issues/642#issuecomment-1167331986 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 27 June 2022 13:08:34 UTC