[ https://issues.apache.org/jira/browse/TS-4312?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15240597#comment-15240597 ]
ASF GitHub Bot commented on TS-4312: ------------------------------------ Github user jpeach commented on a diff in the pull request: https://github.com/apache/trafficserver/pull/541#discussion_r59663241 --- Diff: proxy/hdrs/URL.cc --- @@ -1846,4 +1823,42 @@ REGRESSION_TEST(VALIDATE_HDR_FIELD)(RegressionTest *t, int /* level ATS_UNUSED * } } + +const static struct { + const char *const uri; + bool valid; +} http_strict_uri_parsing_test_case[] = {{"/home", true}, + {"/path/data?key=value#id", true}, + {"/ABCDEFGHIJKLMNOPQRSTUVWXYZ", true}, + {"/abcdefghijklmnopqrstuvwxyz", true}, + {"/0123456789", true}, + {":/?#[]@", true}, + {"!$&'()*+,;=", true}, + {"-._~", true}, + {"%", true}, + {"\n", false}, + {"\"", false}, + {"<", false}, + {">", false}, + {"\\", false}, + {"^", false}, + {"`", false}, + {"{", false}, + {"|", false}, + {"}", false}, + {"é", false}}; + +REGRESSION_TEST(STRICT_URI_PARSING)(RegressionTest *t, int /* level ATS_UNUSED */, int *pstatus) --- End diff -- Wrap the test and it's data in ``#ifdef TS_HAS_TESTS``. > Adding config to parse urls according to RFC > -------------------------------------------- > > Key: TS-4312 > URL: https://issues.apache.org/jira/browse/TS-4312 > Project: Traffic Server > Issue Type: Bug > Reporter: Shen Zhang > Assignee: Brian Geffon > Fix For: 7.0.0 > > > Adding a config option "proxy.config.http.strict_uri_parsing" to sends http > status code 400 back to client if the URL includes non-RFC 3986 compliant > character -- This message was sent by Atlassian JIRA (v6.3.4#6332)