MINOR: uri_normalizer: Add `fragment-strip` normalizer

This normalizer strips the URI's fragment component which should never be sent
to the server.

See GitHub Issue #714.
diff --git a/reg-tests/http-rules/normalize_uri.vtc b/reg-tests/http-rules/normalize_uri.vtc
index 42c4c42..792bea5 100644
--- a/reg-tests/http-rules/normalize_uri.vtc
+++ b/reg-tests/http-rules/normalize_uri.vtc
@@ -8,7 +8,7 @@
 server s1 {
     rxreq
     txresp
-} -repeat 63 -start
+} -repeat 66 -start
 
 haproxy h1 -conf {
     global
@@ -125,6 +125,18 @@
 
         default_backend be
 
+    frontend fe_fragment_strip
+        bind "fd@${fe_fragment_strip}"
+
+        http-request set-var(txn.before) url
+        http-request normalize-uri fragment-strip
+        http-request set-var(txn.after) url
+
+        http-response add-header before  %[var(txn.before)]
+        http-response add-header after  %[var(txn.after)]
+
+        default_backend be
+
     backend be
         server s1 ${s1_addr}:${s1_port}
 
@@ -471,3 +483,20 @@
     rxresp
     expect resp.status == 400
 } -run
+
+client c9 -connect ${h1_fe_fragment_strip_sock} {
+    txreq -url "/#foo"
+    rxresp
+    expect resp.http.before == "/#foo"
+    expect resp.http.after == "/"
+
+    txreq -url "/%23foo"
+    rxresp
+    expect resp.http.before == "/%23foo"
+    expect resp.http.after == "/%23foo"
+
+    txreq -req OPTIONS -url "*"
+    rxresp
+    expect resp.http.before == "*"
+    expect resp.http.after == "*"
+} -run