Skip to content

It's not possible to serve HEAD request with Content-Lenght #4481

@APshenkin

Description

@APshenkin

In HttpMethods

val HEAD = register(HttpMethod("HEAD" , isSafe = true , isIdempotent = true , requestEntityAcceptance = Disallowed, contentLengthAllowed = contentLengthAllowedForHead))

For HEAD method contentLengthAllowed = contentLengthAllowedForHead, which return false for all cases.

This actually doesn't allow to specify Content-Lenght in responses, that may cause unexpected behaviours. For example if you serve Windows appInstaller, it tries to fetch HEAD to understand Content-Lenght to fetch later with Range Header. And without Content-Lenght it fails to install it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    1 - triagedTickets that are safe to pick up for contributing in terms of likeliness of being accepted

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions