You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2024/11/03 08:45:13 UTC
[Bug 69379] HEAD request behavior change does no adhere to RFC 9110
https://bz.apache.org/bugzilla/show_bug.cgi?id=69379
--- Comment #6 from morm@jfrog.com ---
It is as simple as this:
On Tomcat 9.x.x and Jersey, create an empty resource accepting HEAD requests:
@HEAD
@Path("/test/head")
public Response testHead() {
return Response.ok().build();
}
curl --head http://<host:port>/test/head
Observe no `Content-length' header returned.
Do the same on Tomcat 10.x.x.
Observe `Content-length: 0` returned.
Now imagine a client expecting `Content-length` header to be returned if and
only if there is actual content. This is a behavioral change and essentially a
bug.
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org