[WebKit-devel] [Bug 261223] Download name of link targets containing special characters get ignored

Rolf Eike Beer kde at opensource.sf-tec.de
Thu Jan 6 23:37:23 CET 2011


https://bugs.kde.org/show_bug.cgi?id=261223


Rolf Eike Beer <kde at opensource.sf-tec.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID




--- Comment #9 from Rolf Eike Beer <kde opensource sf-tec de>  2011-01-06 23:37:22 ---
The browsers behave absolutely correct: they ignore wrong values. The server
_must_ send everything that does not fall into US-ASCII as quoted string (and
even strings that have a special set of US-ASCII characters).

A header is a key=value field, where value may either be a "token" or a "quoted
string". Of course there are rules for tokens:

This comes from RfC 2616, section 2.2
(http://tools.ietf.org/html/rfc2616#section-2.2):

CHAR           = <any US-ASCII character (octets 0 - 127)>
token          = 1*<any CHAR except CTLs or separators>

This RfC also says:

Many HTTP/1.1 header field values consist of words separated by LWS or special
characters. These special characters MUST be in a quoted string to be used
within a parameter value (as defined in section 3.6).

So the server just sends garbage and the browser just ignores it. There would
be other ways of solving this problem by guessing, but guessing would fail
sometimes and make the code much more complicated. And at the end that's were
rules are for, to make it clear how this stuff has to look like. So please go
and bug save.tv to fix their JavaScript.

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the WebKit-devel mailing list