Skip to content

GET requests include Content-Type header #259

@achingbrain

Description

@achingbrain

The conformance suite sends Content-Type headers in GET requests:

Actual Request:
GET /ipfs/bafyreibs4utpgbn7uqegmd2goqz4bkyflre2ek2iwv743fhvylwi4zeeim/ HTTP/1.1·
Host: 127.0.0.1:3334·
User-Agent: ipfs/gateway-conformance/dev·
Accept: application/vnd.ipld.dag-json·
Content-Type: application/vnd.ipld.dag-json·
Range: bytes=7-9·····························

RFC 7231 says:

3.1.1.5. Content-Type

The "Content-Type" header field indicates the media type of the associated representation: either the representation enclosed in the message payload or the selected representation, as determined by the message semantics.

This means Content-Type is only used for requests that have a body, e.g. POST or PUT.

It should not be present in GET requests.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions