Re: WF2: application/x-www-form-urlencoded encoding ill-defined

On 2006/09/05, at 6:47 PM, Bjoern Hoehrmann wrote:
>
> This text is rather unclear and incorrect; it does not define what  
> non-
> alphanumeric characters are (and whatever it means, it's incorrect),

The best way to fix this would be with direct references to RFC3986's  
BNF.

You'd probably want to encode anything that doesn't match the  
unreserved rule, adding parts of the reserved rule depending on the  
context (i.e., if it's in a query arg, you can allow sub-delims, ":",  
"@", "/" and "?"; if it can appear in a path segment, you have to  
percent-encode the last two).


> the
> character encoding is applied to the whole string, not just non-alpha-
> numeric characters,

Sort of. The input to the function is a unicode string; it doesn't  
have any encoding. Then, the characters which need to be percent- 
encoded (see above) are serialised as UTF-8 and the resulting bytes  
are percent-encoded and inserted as characters. Then, the entire  
thing is serialised as a UTF-8 string (unless the WG wants to allow  
other encodings; I don't have the context handy).

Cheers,

--
Mark Nottingham
mnot@yahoo-inc.com

Received on Thursday, 7 September 2006 16:08:15 UTC