diff -ru nginx-0.8.29/src/http/ngx_http_parse.c nginx-0.8.29.method/src/http/ngx_http_parse.c --- nginx-0.8.29/src/http/ngx_http_parse.c 2009-09-25 04:30:06.000000000 -0500 +++ nginx-0.8.29.method/src/http/ngx_http_parse.c 2009-11-30 20:59:06.000000000 -0600 @@ -266,7 +266,11 @@ /* space* before URI */ case sw_spaces_before_uri: - if (ch == '/' ){ + if (r->method & NGX_HTTP_UNKNOWN) { + return NGX_HTTP_PARSE_INVALID_METHOD; + } + + if (ch == '/') { r->uri_start = p; state = sw_after_slash_in_uri; break;