You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expected: lenient parsing seems to accept Transfer-Encoding: chunked and Content-Length set at the same time. Is that the expected behaviour? Does it accept Transfer-Encoding: identity in lenient mode?
Yes, it was a typo on the test, I included in #239.
According to the specs (both RFC 9112 which the most recent and RFC 7230 which llhttp implements) , Content-Length "SHOULD NOT" be sent when Transfer-Encoding is present. If it still happens, the latter should override the former.
llhttp is a bit stricter on this and forbids (when non in lenient mode) the conflict without attempting to resolve it. The value of the headers doesn't matter, their mere presence is enough.
Activity
ShogunPanda commentedon Aug 7, 2023
Yes, it was a typo on the test, I included in #239.
According to the specs (both RFC 9112 which the most recent and RFC 7230 which llhttp implements) ,
Content-Length"SHOULD NOT" be sent whenTransfer-Encodingis present. If it still happens, the latter should override the former.llhttp is a bit stricter on this and forbids (when non in lenient mode) the conflict without attempting to resolve it. The value of the headers doesn't matter, their mere presence is enough.