chunksize doesn't match the result after response mutation
Brought to you by:
likexx
For HTTP 1.1, after response is received, if the responded HTTP set "Transfer-Encoding" as "chunk", there is an interger at the very beginning of the whole content, sort of:
HTTP RESPONSE
\r\n
\r\n
chunk size (integer binary)
\r\n
HTML data...
the chunk size looks like an exact match for the HTML content. Since mutation will change the content size, the chunk size is not updated, and the browser will close the socket in such situation and shows website cannot be displayed.