-
Bug
-
Resolution: Done
-
Major
-
2.2.17.Final
-
None
When using an asynchronous WriteListener, the ServletOutputStreamImpl assumes that if not content has been written, the Content-Length header should be set to 0. See https://github.com/undertow-io/undertow/blob/20d777c181264f749a39fca7003dc9441687faa9/servlet/src/main/java/io/undertow/servlet/spec/ServletOutputStreamImpl.java#L680
Unfortunately, this has the side effect that HEAD requests, for which no response body should be written, always end up with Content-Length 0. Even when the servlet sets the Content-Length header correctly, to whatever value you would have for a GET request.
- causes
-
JBEAP-23796 [QA](7.4.z) UNDERTOW-2116 - java.lang.AssertionError: Content-Encoding header should be defined
- Closed
- is caused by
-
UNDERTOW-2070 Empty reply from Undertow if sendRedirect is called after setting content length
- Closed
- is incorporated by
-
UNDERTOW-2507 Get 2.0.41.SP branch in good shape
- Resolved
-
WFCORE-6057 Upgrade Undertow to 2.3.0.Final (CVE-2022-2764)
- Closed