On 19 February 2016 at 19:09, Ben Caradoc-Davies <b...@transient.nz> wrote:

>
> Also, ResponseUtils.urlEncode and ResponseUtils.urlDecode use:
>>> URLEncoder.encode(value, "ISO-8859-1")
>>> URLDecoder.decode(value, "ISO-8859-1")
>>> which I think should be changed to "UTF-8". Leaving this as
>>> "ISO-8859-1" is going to break a lot more things.
>>>
>> Agreed, this is plain wrong. UTF-8 is the standard for percent encoding.
>>
>
> Should check the HTML spec to see that this not mandated. I think it was
> updated to UTF-8 but I am not sure.


I started looking yesterday... and quickly figured out it was a massive can
of worms, and decided to not reply :)

>From what I can tell
* current HTTP1.1 RFC2231: header values should be encoded using ISO8859-1
* proposed HTTP1.1 RFC7230: US-ASCII (because support is inconsistent for
other encodings)
* for alternative encodings, use RFC5987:

  Foo: =?UTF-8?Q?Some%20Encoded%20Text?=


But this is mostly used for client interpretations of *attachment
filenames* via
the Content-Disposition header, and browsers *appear* to try ISO8859-1 then
UTF-8 if the encoding isn't specified. See RFC6266 which specifically talks
about that, and https://bugzilla.mozilla.org/show_bug.cgi?id=601933 talks
about it from a browser perspective.

For the current discussion as long as the client gives the Parent URL back
to us and we reinterpret it the same way then we're good, it doesn't
really matter what the encoding is.

If this code is also used for setting response filenames (I guess it is)
then go read all those RFCs ^^^ and make some more sense out of them?

¯\_(ツ)_/¯

Rob :)
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to