zencoder-php icon indicating copy to clipboard operation
zencoder-php copied to clipboard

Zencoder failing behind proxy which injects an incorrect Content-Type header

Open craiga opened this issue 10 years ago • 1 comments
trafficstars

I'm seeing some odd behaviour when I send a request to Zencoder from behind our corporate proxy.

It looks like an extra set Content-Type header is being set, which causes Zencoder to throw a Services_Zencoder_Exception with the message Unexpected content type: text/html (HTTP/1.1 100 Continue).

The response looks like this:

HTTP/1.0 200 Connection Established
Content-Type: text/html
Via: 1.0 ABCDEFGHIJK
Connection: Keep-Alive
Proxy-Connection: Keep-Alive

HTTP/1.1 100 Continue

HTTP/1.1 201 Created
Server: ZenServer 0.1.9
Date: Thu, 15 Jan 2015 03:45:48 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 184
Connection: close
Strict-Transport-Security: max-age=31536000
X-Zencoder-Rate-Remaining: 1000
ETag: "235caea52f485e3baf42c44482bde6af"
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: GET, POST, PUT, DELETE
Access-Control-Allow-Headers: Zencoder-Api-Key
Access-Control-Max-Age: 300
Cache-Control: private, max-age=0, must-revalidate

{"id":136990733,"outputs":[{"id":408898097,…

craiga avatar Jan 15 '15 03:01 craiga

I'm intending on sending through a pull request for this issue which you may or may not wish to accept. This issue is just to document the problem I'm hoping to solve.

craiga avatar Jan 15 '15 03:01 craiga