Forum: NGINX No HTTP version in request

Posted by Matthieu Tourne (Guest)
on 2013-03-20 02:48
(Received via mailing list)
I just found an interesting behavior in Nginx while looking at a reqeust
that was causing an error in my code.

For a request with no HTTP/xx version, Nginx will return no HTTP 
response
headers.

From what I gathered, this is just Nginx defaulting to HTTP/0.9, where 
no
headers are expected. And actually doing the right thing here.

But shouldn't $server_protocol default to HTTP/0.9 in that case, instead 
of
being an empty string ?
Posted by Igor Sysoev (Guest)
on 2013-03-20 06:04
(Received via mailing list)
On Mar 20, 2013, at 5:47 , Matthieu Tourne wrote:

> I just found an interesting behavior in Nginx while looking at a reqeust that 
was causing an error in my code.
>
> For a request with no HTTP/xx version, Nginx will return no HTTP response 
headers.
>
> From what I gathered, this is just Nginx defaulting to HTTP/0.9, where no 
headers are expected. And actually doing the right thing here.
>
> But shouldn't $server_protocol default to HTTP/0.9 in that case, instead of 
being an empty string ?


Yes, absence of protocol version is so called HTTP/0.9 but this is adhoc 
name, so I think empty string
is correct value, since there is no protocol version at all.
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.