--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPVbROrjo%3D%2BQ-3HSV26-gVKT6nBfvWucnzRowa%2B1MJizuD7Gxg%40mail.gmail.com.
The HTML standard specifically overrides the RFC in this case, by specifying that browsers will do fallback character encoding (in an unspecified manner!) for file names prior to following the RFC-defined steps for form data encoding. From html.spec.whatwg.org/multipage/form-control-infrastructure.html#multipart-form-data :"File names included in the generated multipart/form-data resource (as part of file fields) must use the character encoding selected above, though the precise name may be approximated if necessary (e.g. newlines could be removed from file names, quotes could be changed to "%22", and characters not expressible in the selected character encoding could be replaced by other characters)."
On Tuesday, November 7, 2017 at 5:52:31 PM UTC-8, Victor Costan wrote:Clarification for the Spec field:I think that the filename is a field in should be covered by RFC 7578 [1]. However, as the e-mail states, browser implementations deviate from the behaviors recommended in the RFC. I think that we should follow other implementations and get this decision documented.VictorOn Tue, Nov 7, 2017 at 5:42 PM, Benjamin Wiley Sittler <bsit...@chromium.org> wrote:bsit...@chromium.org None (this aspect of character encoding error handling is not yet specified in the HTML standard) Change <input type="file"> filename encoding in multipart/form-data uploads in forms with non-Unicode accept-charset to use HTML-style numeric character references rather than '?' when a filename the user selects contains characters not representable in the target character encoding. This change would align our behavior with the existing behavior of Firefox and Edge. It is hoped that this behavior can eventually reach cross-browser consensus and standardization.--This character encoding interoperability bugfix in a non-standardized part of the web platform will reduce accidental data loss for some web forms still using character sets not able to represent the full Unicode character repertoire in file uploads when the file the user chooses to upload is named using one or more characters that are not representable in the character encoding specified in the form's accept-charset or inherited from the web page. Once Chrome, Firefox and Edge all have interoperable fallback encoding it should be proposed for inclusion in the standard. Firefox: Shipped (see results in https://crbug.com/661819) Edge: Shipped (see results in https://crbug.com/661819#c4) Safari: No public signals Web developers: No signalsI believe this change poses no interoperability risk given that Edge and Firefox already do this and have for at least a year and quite likely much longer. I believe this change poses very little compatibility risk. To applications the only visible change should be that some form submissions that formerly uploaded files apparently having '?' in their names from Chrome will henceforth instead upload files apparently having '&#NNNNN;' in their names, exactly as if those uploads had been made using Firefox or Edge.None.Yes.
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPVbROrjo%3D%2BQ-3HSV26-gVKT6nBfvWucnzRowa%2B1MJizuD7Gxg%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/8665bee3-b848-428a-a661-9744bc5200ba%40chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPAtzjruS3hyqKB62V%3DyfmYfM_rt_Qn1CaV%3DtBFdmdoqLZtzmA%40mail.gmail.com.
On Wed, Nov 8, 2017 at 6:28 AM, Rick Byers <rby...@chromium.org> wrote:
> I think it's debatable the extent to which this is web exposed (and so
> requires an intent). I.e. there's no way for JS to observe what filename
> was actually used (except indirectly by, eg., asking the user to upload it),
> right? To what extent might it make sense to try to test this behavior with
> web-platform-tests?
Exposed to the server is web-exposed. But also, this is exposed
directly to JavaScript through <input>.files. And some oddities get
exposed through the FormData API and Request and Response objects
(their formData() method).
https://www.w3.org/Bugs/Public/show_bug.cgi?id=16909 has some
information on other issues with multipart/form-data and there's been
various other things that popped up over the years. At some point
someone is going to have to write lots of tests and figure out a
sensible parser and serializer that meet all the various compatibility
requirements.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CADnb78ivY8jQR0U5PTaLjvpYJOoC6bn77t%2B-9yiJX72ofAjpQQ%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAKNmLGr_Ot3QBvRknjdzjXUGxc0kXqRvRhnJjWGA1gRvDLO%2BHw%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CADnb78ita7NK6HY8CyFHJ%3DzMW51hprXvTBN%3DZTZPZ36vXOgCog%40mail.gmail.com.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPAtzjr_qOB8Q0Wc%2BUaM9KhVdhw%3D63bJszno6ZiUJsGE6tHP4w%40mail.gmail.com.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAPAtzjr_qOB8Q0Wc%2BUaM9KhVdhw%3D63bJszno6ZiUJsGE6tHP4w%40mail.gmail.com.