Welcome! Log In Create A New Profile

Advanced

Re: Cannot remove Content Length header

Luc Juggery
September 24, 2011 09:08AM
Hello,

I'm testing it from a browser and with curl as well and I got the same.
When I bypass nginx the response is correct. When I request from nginx, the lenght is added at the beginning and 0 at the end of the json I would expect.

--
Luc

Le Sep 24, 2011 à 13:49, Richard Kearsley <Richard.Kearsley@m247.com> a écrit :

> How are you testing it?
> That looks like results I saw using telnet but those numbers do not appear with a http client such as curl
>
>
> On 24 Sep 2011, at 12:43, "Luc Juggery" <luc.juggery@gmail.com> wrote:
>
>> Hello,
>>
>> I'm using Nginx as a front end to my node.js application, nginx proxying https request to my app.
>> When the browser gets the response back, instead of pure json ({"error":"query error","message":"Parameter(s) missing: user,password"}), I receive something like:
>>
>> 47
>> {"error":"query error","message":"Parameter(s) missing: user,password"}
>> 0
>>
>> I use 'more_clear_headers' module but do not have any luck.
>>
>> This is the config I use:
>>
>> server {
>> listen 443;
>> server_name my.server.com;
>> ssl on;
>> ssl_certificate certificate.pem;
>> ssl_certificate_key privatekey.pem;
>>
>> keepalive_timeout 70;
>>
>> location / {
>> more_clear_headers 'Content-Length'; # Does not work as I would expect
>> proxy_pass https://localhost:8443;
>> proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
>> proxy_set_header Host $http_host;
>> proxy_buffering off;
>> proxy_buffers 8 8k;
>> }
>> }
>>
>> Would you have any idea ?
>> Thanks a lot for your help,
>>
>> --
>> Luc
>
>> _______________________________________________
>> nginx mailing list
>> nginx@nginx.org
>> http://mailman.nginx.org/mailman/listinfo/nginx
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Cannot remove Content Length header

Luc Juggery September 24, 2011 07:44AM

Re: Cannot remove Content Length header

Richard Kearsley September 24, 2011 07:50AM

Re: Cannot remove Content Length header

Luc Juggery September 24, 2011 09:08AM

Re: Cannot remove Content Length header

Maxim Dounin September 24, 2011 08:06AM

Re: Cannot remove Content Length header

Luc Juggery September 24, 2011 09:00AM

Re: Cannot remove Content Length header

Maxim Dounin September 24, 2011 10:56AM

Re: Cannot remove Content Length header

Luc Juggery September 24, 2011 01:26PM

Re: Cannot remove Content Length header

Luc Juggery September 25, 2011 12:08PM

Re: Cannot remove Content Length header

Sandesh K. September 26, 2011 04:18AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 150
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready