Skip to content

ddclient makes invalid HTTP requests #332

@rrthomas

Description

@rrthomas

I noticed a problem recently where my updates were being refused despite valid credentials with "400 Bad Request". On investigation, this is because ddclient is making invalid requests: according to the HTTP 1.0 spec "A valid Content-Length is required on all HTTP/1.0 POST requests."

There are two obvious solutions:

  1. Make ddclient speak HTTP 1.1. This simply requires changing the version number.
  2. Add a Content-Length: 0 header in the case when there is no data being sent.

I've tried both solutions, and both work fine; the first is simpler, but perhaps there are still servers out there that don't speak HTTP 1.1?

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