Unverified Commit 8dcda468 authored by Keshav Prasad's avatar Keshav Prasad Committed by GitHub
Browse files

fix: verify if url starts with the pattern (#3045)

Showing with 2 additions and 1 deletion
+2 -1
......@@ -12,7 +12,8 @@ default allow = {
urls[keys] { policy.urls_to_action_mapping[keys]}
identified_url := regex.find_n(urls[_], http_request.path, 1)[0]
matching_url := regex.find_n(urls[_], http_request.path, 1)[0]
identified_url := matching_url {startswith(matching_url, http_request.path)}
identified_action := policy.urls_to_action_mapping[identified_url]
allow {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment