A document should be added to DOM indicating network errors due to invalid header values
Categories
(Core :: Networking, defect, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox138 | --- | fixed |
People
(Reporter: ats, Assigned: sekim)
References
(Blocks 1 open bug)
Details
(Whiteboard: [necko-triaged][necko-priority-queue])
Attachments
(3 files)
Steps to reproduce:
Visit a webpage which returns a header containing a null value (\x00).
Actual results:
- Firefox returns a network error (NS_ERROR_DOM_INVALID_HEADER_VALUE) as per spec.
- No document is added to DOM indicating error.
Expected results:
An error document (eg: about:error) should be added to DOM for better user experience. This also causes tests for headers with null values to fail.
This is a follow-up bug from https://bugzilla.mozilla.org/show_bug.cgi?id=1891465 & https://github.com/web-platform-tests/wpt/pull/48855.
Comment 1•8 months ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Networking' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Comment 2•8 months ago
|
||
Hi Sean,
I think you might be interested in this bug as well.
Thanks.
Assignee | ||
Updated•8 months ago
|
Assignee | ||
Updated•8 months ago
|
Assignee | ||
Comment 3•8 months ago
|
||
Assignee | ||
Comment 4•8 months ago
|
||
Hello Kershaw,
Do you have any suggestions for the error message?
Thank you
Comment 5•8 months ago
|
||
(In reply to Sean Kim from comment #4)
Hello Kershaw,
Do you have any suggestions for the error message?
Thank you
Maybe something like:
A header received from the server contains prohibited null characters (0x00).
I would suggest you to also ask in #content_design.
Thanks.
Assignee | ||
Updated•6 months ago
|
Updated•6 months ago
|
Assignee | ||
Comment 6•6 months ago
|
||
https://hg.mozilla.org/mozilla-central/rev/e37c1dbf5004
https://hg.mozilla.org/mozilla-central/rev/f7983c22a75f
Assignee | ||
Comment 9•6 months ago
|
||
Comment 10•6 months ago
|
||
Comment 11•6 months ago
|
||
Backed out for causing lint failures
Backout link: https://hg.mozilla.org/integration/autoland/rev/ca1baad7a3999872b8055a17de5b89ebffd96aa8
Comment 12•6 months ago
|
||
bugherder |
Updated•6 months ago
|
Comment 13•6 months ago
|
||
Comment 14•6 months ago
|
||
Making significant changes to a patch after review is generally not OK.
Recording here for a follow-up, since there is already a needinfo open.
+blockedByCORP=Firefox didn’t load this page because it looks like the security configuration doesn’t match the previous page.
DOM is supposed to be browser-agnostic, so having "Firefox" is a string is incorrect (although there is at least one in the file).
The browser didn’t load this page because it looks like the security configuration doesn’t match the previous page.
Even the string in /browser
shouldn't have Firefox
hard-coded (linters would have caught that for .ftl
), it should be a placeholder replaced at run-time. This makes it impossible for other browsers to expose their own name instead of Firefox.
Note that the fix will require a new string ID.
Comment 15•6 months ago
|
||
bugherder |
Comment 16•6 months ago
|
||
A patch has been attached on this bug, which was already closed. Filing a separate bug will ensure better tracking. If this was not by mistake and further action is needed, please alert the appropriate party. (Or: if the patch doesn't change behavior -- e.g. landing a test case, or fixing a typo -- then feel free to disregard this message)
Assignee | ||
Comment 17•6 months ago
•
|
||
(In reply to Francesco Lodolo [:flod] from comment #14)
Making significant changes to a patch after review is generally not OK.
Recording here for a follow-up, since there is already a needinfo open.
+blockedByCORP=Firefox didn’t load this page because it looks like the security configuration doesn’t match the previous page.
DOM is supposed to be browser-agnostic, so having "Firefox" is a string is incorrect (although there is at least one in the file).
The browser didn’t load this page because it looks like the security configuration doesn’t match the previous page.
Even the string in
/browser
shouldn't haveFirefox
hard-coded (linters would have caught that for.ftl
), it should be a placeholder replaced at run-time. This makes it impossible for other browsers to expose their own name instead of Firefox.Note that the fix will require a new string ID.
Sorry about that, I assumed that it was fine to do so since I copied the lines of code from appstring.properties in browser/. I just filed a new bug -- https://bugzilla.mozilla.org/show_bug.cgi?id=1952234 -- we should back this patch out and only add invalidHeaderValue
. Bug 1952244 should handle a browser-agnostic message for blockedByCORP
.
Comment 18•6 months ago
|
||
Backed out as requested: https://hg.mozilla.org/integration/autoland/rev/23ff917a28f60182ae32440b618ffe2a787e20b3
Assignee | ||
Updated•6 months ago
|
Comment 19•6 months ago
|
||
Backout merged to central: https://hg.mozilla.org/mozilla-central/rev/23ff917a28f6
Updated•6 months ago
|
Comment 20•5 months ago
|
||
Comment 21•5 months ago
|
||
bugherder |
Assignee | ||
Updated•5 months ago
|
Description
•