]> git.kaiwu.me - nginx.git/commitdiff
Allowed digits, '+', '-', and '.' in scheme names as per RFC 3986.
authorRuslan Ermilov <ru@nginx.com>
Thu, 24 May 2018 09:06:35 +0000 (12:06 +0300)
committerRuslan Ermilov <ru@nginx.com>
Thu, 24 May 2018 09:06:35 +0000 (12:06 +0300)
src/http/ngx_http_parse.c

index 844054c9dc7b1679886df6ea680c57c7991952d8..d9a1dbedb59df14c25217f4e4b33009d559b990f 100644 (file)
@@ -307,6 +307,11 @@ ngx_http_parse_request_line(ngx_http_request_t *r, ngx_buf_t *b)
                 break;
             }
 
+            if ((ch >= '0' && ch <= '9') || ch == '+' || ch == '-' || ch == '.')
+            {
+                break;
+            }
+
             switch (ch) {
             case ':':
                 r->schema_end = p;