﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc	uname	nginx_version
1371	some url contains space will be treated as invalid	Alex Zhang		"Hi!

So i have two url, both of them contain the space, one is ""/foo/blah Hello"", and the other is ""/foo/blah Yeah"", i found the former will be treated as invalid and got the `400 Bad Request` while the latter doesn't.

You can reproduce this by the following configuration.

{{{
server {
    listen 8082;
    server_name _;

    location /foo/blah {
        return 200;
    }
}
}}}

{{{
curl -I ""http://127.0.0.1:8082/foo/blah Hello""
HTTP/1.1 400 Bad Request
Server: nginx/1.13.4
Date: Wed, 30 Aug 2017 02:31:33 GMT
Content-Type: text/html
Content-Length: 173
Connection: close
}}}

{{{
curl -I ""http://127.0.0.1:8082/foo/blah Yeah""
HTTP/1.1 200 OK
Server: nginx/1.13.4
Date: Wed, 30 Aug 2017 02:31:53 GMT
Content-Type: application/octet-stream
Content-Length: 0
Connection: keep-alive
}}}

I found the reason is that when space in uri and the next character after the space is 'H', function ngx_http_parse_request_line will try to match the word `HTTP`, so 'T' is expected after 'H', otherwise `NGX_HTTP_PARSE_INVALID_REQUEST` will be returned so `400 Bad Request` will be printed.

I'm wondering if this is a bug or just the expected behavior?  "	defect	closed	minor		nginx-module	1.13.x	duplicate	ngx_http_parse_request_line		Linux Fedora26-64 4.12.5-300.fc26.x86_64 #1 SMP Mon Aug 7 15:27:25 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux	"nginx version: nginx/1.13.4
built by gcc 7.1.1 20170622 (Red Hat 7.1.1-3) (GCC)
configure arguments: --prefix=/home/alex/bin_install/nginx"
