lua-resty-radixtree
lua-resty-radixtree copied to clipboard
bug: parameter in path matching fails on percent encoding in the URI
When APISIX calls dispatch
it sends Nginx normalized URI which decodes percent encoded characters, i.e. /uri%20contains%20space
would become /uri contains space
. The matching behavior of radixtree should be aware of this decoding. Steps to reproduce
- Create a new matching rule with a parameter in path
{
paths = { "/test/:id/update" },
methods = { "GET" },
}
- Match the rule with an URI that contains space, e.g.
/test/contains space/update
- The URI is expected to match the parameter
:id
but it does not.