Last Comment Bug 672079 - bad handling of single quotes inside HTTP Link header fields
: bad handling of single quotes inside HTTP Link header fields
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: DOM (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla8
Assigned To: Julian Reschke
:
Mentors:
http://greenbytes.de/tech/tc/httplink...
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-07-16 14:22 PDT by Julian Reschke
Modified: 2011-08-01 07:50 PDT (History)
1 user (show)
bzbarsky: in‑testsuite?
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
remove special treatment of single quotes (1003 bytes, patch)
2011-07-25 15:25 PDT, Julian Reschke
bzbarsky: review+
Details | Diff | Review

Description Julian Reschke 2011-07-16 14:22:13 PDT
The parser for Link header fields treats single quotes just like double quotes.

In some cases, this is just an annoyance because it accepts values other UAs may not accept:

  http://greenbytes.de/tech/tc/httplink/#simplecsssq

What's worse is that it misinterprets valid parameters that use the token format, where the single quote is a "normal" character without special treatment:

  http://greenbytes.de/tech/tc/httplink/#simplecsstitle5987r

I recommend simply removing the special casing for single quotes. This fixes the second test case, and established parity with Opera in the first one.
Comment 1 Julian Reschke 2011-07-25 15:25:25 PDT
Created attachment 548306 [details] [diff] [review]
remove special treatment of single quotes

This fixes two more cases on http://greenbytes.de/tech/tc/httplink/
Comment 2 Boris Zbarsky [:bz] 2011-07-28 13:02:47 PDT
Comment on attachment 548306 [details] [diff] [review]
remove special treatment of single quotes

OK, let's give this a shot....
Comment 4 Marco Bonardo [::mak] 2011-08-01 07:50:49 PDT
http://hg.mozilla.org/mozilla-central/rev/37dcfd002ab0

Note You need to log in before you can comment on or make changes to this bug.