Closed Bug 945215 Opened 11 years ago Closed 10 years ago

Map HZ to the replacement encoding

Categories

(Core :: Internationalization, defect, P4)

defect

Tracking

()

RESOLVED FIXED
mozilla35

People

(Reporter: hsivonen, Assigned: hsivonen)

References

()

Details

(Keywords: sec-want)

Attachments

(2 files, 2 obsolete files)

Once bug 935453 has been out on the release channel for six weeks, we should evaluate the results and see if we can get away with mapping HZ to the replacement encoding. (HZ is the most XSS-exploitable one of the encodings we support.)
Keywords: sec-want
Priority: -- → P4
Summary: Consider mapping HZ to the replacement encoding → Map HZ to the replacement encoding
Per https://www.w3.org/Bugs/Public/show_bug.cgi?id=25339#c4 and https://codereview.chromium.org/265973003 Blink landed this about four months ago. Perhaps we should follow?
Attached patch Map HZ to replacement, v3 (deleted) — Splinter Review
https://tbpl.mozilla.org/?tree=Try&rev=913b8d2ed3a0 I'm not removing the encoder and decoder from the tree in this patch in order to avoid rotting my queue. I'll do it as a follow-up.
Attachment #8419989 - Attachment is obsolete: true
Comment on attachment 8493629 [details] [diff] [review] Map HZ to replacement, v3 Review of attachment 8493629 [details] [diff] [review]: ----------------------------------------------------------------- ::: intl/uconv/tests/unit/test_bug367026.js @@ -1,1 @@ > -/* Tests conversion from Unicode to HZ-GB-2312 (bug 367026) Could you preserve the test until you remove the encoder and decoder? ::: intl/uconv/tests/unit/test_bug90411.js @@ -1,1 @@ > -/* Test case for bug 90411 Ditto.
Attachment #8493629 - Flags: review?(VYV03354) → review+
(In reply to Masatoshi Kimura [:emk] from comment #8) > ::: intl/uconv/tests/unit/test_bug367026.js > @@ -1,1 @@ > > -/* Tests conversion from Unicode to HZ-GB-2312 (bug 367026) > > Could you preserve the test until you remove the encoder and decoder? I landed with that test preserved. Thanks. https://hg.mozilla.org/integration/mozilla-inbound/rev/75c44bd10b14 > ::: intl/uconv/tests/unit/test_bug90411.js > @@ -1,1 @@ > > -/* Test case for bug 90411 > > Ditto. This one I didn't preserve, because it used a conversion mechanism that doesn't allow Encoding Standard label handling to be bypassed.
sorry had to backout this change since we had test failures in web platform test 2 like https://tbpl.mozilla.org/php/getParsedLog.php?id=48760797&tree=Mozilla-Inbound
(In reply to Carsten Book [:Tomcat] from comment #10) > sorry had to backout this change since we had test failures in web platform > test 2 like > https://tbpl.mozilla.org/php/getParsedLog.php?id=48760797&tree=Mozilla- > Inbound Sorry about that. This is what I get from trying to save tryserver resources. :-( Now I need to learn to work with Web Platform Tests.
James, attachment 8494478 [details] [diff] [review] points out some things where we have expected FAIL. Ideally these tests are updated somehow, including upstream. They probably want to expect the label "replacement", except for the "x-user-defined" one, not sure why that is FAIL.
The expectation just refers to what we expect Gecko to actually do, not what the spec expects. If the tests are wrong per spec they should indeed be fixed upstream. Does one of you have the time to do that? I don't know encoding stuff too well.
Okay, so we fix upstream first? I can help.
(In reply to Henri Sivonen (:hsivonen) from comment #12) > Created attachment 8494478 [details] [diff] [review] > Web Platform expectation addendum > > https://tbpl.mozilla.org/?tree=Try&rev=e82a2a40b497 Weird. Tryserver ran SpiderMonkey tests instead. (In reply to Anne (:annevk) from comment #15) > Okay, so we fix upstream first? Let's fix this in parallel. If fixed upstream gets pulled in first, great. If not, let's land this with expected fail.
Let's see if *this* try run includes Web Platform Tests: https://tbpl.mozilla.org/?tree=Try&rev=c1db47c4471d
(In reply to Henri Sivonen (:hsivonen) from comment #17) > Let's see if *this* try run includes Web Platform Tests: > https://tbpl.mozilla.org/?tree=Try&rev=c1db47c4471d W2 results not shown. Why might that be? W1 and W4 are shown.
Flags: needinfo?(james)
Ms2ger pointed out that the results were green but hidden on try.
Flags: needinfo?(james)
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla35
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: