Header Content-Type shouldn't be required for media types

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major
    • V4.0_ERRATA03
    • Affects Version/s: V4.0_ERRATA02
    • Component/s: Protocol
    • None
    • Environment:

      Applied

    • Hide

      While we can be more restrictive in OData by requiring the Content-Type header in responses, we want to allow for cases where the upload client doesn't specify a content-type.

      Therefore, we should change Content-type from MUST to SHOULD for media types only. This allows a service to return content received with no content type as either application/octet-stream or without a content type.

      Show
      While we can be more restrictive in OData by requiring the Content-Type header in responses, we want to allow for cases where the upload client doesn't specify a content-type. Therefore, we should change Content-type from MUST to SHOULD for media types only. This allows a service to return content received with no content type as either application/octet-stream or without a content type.
    • Show
      Applied to 8.1.1 Header Content-Type https://www.oasis-open.org/committees/download.php/57689/odata-v4.0-wd08-part1-protocol-2016-03-03.docx

      This section misquotes RFC7231 and states that a Content-Type header MUST be present.

      https://tools.ietf.org/html/rfc7231#section-3.1.1.5 only says SHOULD

      Note that browsers may not specify a content type in some cases. This means that a client can upload a media type without specifying a content-type, the service can store it, and then return the media in a response but may not know what the content-type is (server could return application/octet-stream).

            Assignee:
            Michael Pizzo (Inactive)
            Reporter:
            handl
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: