[
https://issues.apache.org/jira/browse/TS-4312?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15240594#comment-15240594
]
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_r59663218
--- 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 --
We don't use all caps ``STRICT_URI_PARSING``. How about
``ParseRules_strict_URI`` or something?
> 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)