title: Can we use regular expressions in web.xml URL patterns?
body: <p>I am writing a filter to do a specific task but I am unable to set a specific url pattern to my filter. My filter mapping is as follows:</p>
  
  <pre class="lang-xml prettyprint-override"><code> &lt;web.xml&gt;
    &lt;filter&gt;
       &lt;filter-name&gt;myFilter&lt;/filter-name&gt;
       &lt;filter-class&gt;test.MyFilter&lt;/filter-class&gt;
     &lt;/filter&gt;
  
    &lt;filter-mapping&gt;
      &lt;filter-name&gt;myFilter&lt;/filter-name&gt;
       &lt;url-pattern&gt;/org/test/*/keys/*&lt;/url-pattern&gt;
     &lt;/filter-mapping&gt;
   &lt;/web-app&gt;
  </code></pre>
  
  <p>My url-pattern <code>[ /org/test/ * /keys/ * ]</code> is not working as I had expected.</p>
  
  <p>I am calling urls from the browser like:       </p>
  
  <pre class="lang-none prettyprint-override"><code>http://localhost:8080/myapp/org/test/SuperAdminReport/keys/superAdminReport.jsp
  http://localhost:8080/myapp/org/test/Adminreport/keys/adminReport.jsp
  http://localhost:8080/myapp/org/test/OtherReport/keys/otherReport.jsp
  </code></pre>
  
  <p>So for the URLs above the filter pattern should match. How can I achieve this?</p>