HTTP/1: return a network error for responses with no LF after headers
Categories
(Core :: Networking: HTTP, defect, P2)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox88 | --- | fixed |
People
(Reporter: annevk, Assigned: kershaw)
References
Details
(Whiteboard: [necko-triaged])
Attachments
(1 file)
We have rather scary behavior currently when this happens. In particular, when I modify
fetch/h1-parsing/resources/status-code.py and remove the final newline and then run fetch/h1-parsing/status-code.window.js (as fetch/h1-parsing/status-code.window.html) it returns status codes such as 54976 (where 1 is expected) and if you refresh it will list a different status code there. That suggests that something is rather broken.
Tests: https://github.com/web-platform-tests/wpt/pull/27456. (These don't exhibit the above behavior because they expect a network error, as Safari already does. Chrome does not however, but I suspect they would want to align on at least requiring a single newline.)
| Assignee | ||
Updated•5 years ago
|
| Assignee | ||
Comment 1•5 years ago
|
||
Comment 3•5 years ago
|
||
| bugherder | ||
| Reporter | ||
Comment 4•5 years ago
|
||
Hey Kershaw, is there a follow-up bug for the issue found during review? While the test only found this for fetch(), it seems likely that other code also assumes status is available once the network layer returns a response.
| Assignee | ||
Comment 5•5 years ago
|
||
(In reply to Anne (:annevk) from comment #4)
Hey Kershaw, is there a follow-up bug for the issue found during review? While the test only found this for
fetch(), it seems likely that other code also assumes status is available once the network layer returns a response.
Sorry that I forgot to mention I already filed bug 1694361 for this.
Description
•