title: Giving multiple URL patterns to Servlet Filter
body: <p>I am using a Servlet Filter in my JSF application.  I have three groups of Web pages in my application, and I want to check Authentication for these pages in my Servlet Filter:</p>
  
  <p>my Folders</p>
  
  <pre class="lang-none prettyprint-override"><code>/Admin/ *.xhtml
  
  /Supervisor/*.xhtml
  /Employee/*.xhtml
  </code></pre>
  
  <p>and I am writing <code>web.xml</code> like</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;filter&gt;
      &lt;filter-name&gt;LoginFilter&lt;/filter-name&gt;
      &lt;filter-class&gt;com.ems.admin.servlet.LoginFilter&lt;/filter-class&gt;
  &lt;/filter&gt;
  
  &lt;filter-mapping&gt;
      &lt;filter-name&gt;LoginFilter&lt;/filter-name&gt;
      &lt;url-pattern&gt;/Employee/*&lt;/url-pattern&gt;
  &lt;/filter-mapping&gt;
  &lt;filter-mapping&gt;
      &lt;filter-name&gt;LoginFilter&lt;/filter-name&gt;
      &lt;url-pattern&gt;/Admin/*&lt;/url-pattern&gt;
  &lt;/filter-mapping&gt;
  &lt;filter-mapping&gt;
      &lt;filter-name&gt;LoginFilter&lt;/filter-name&gt;
      &lt;url-pattern&gt;/Supervisor/*&lt;/url-pattern&gt;
  &lt;/filter-mapping&gt;
  </code></pre>
  
  <p>but requests like</p>
  
  <pre class="lang-none prettyprint-override"><code>http://localhost:8080/EMS2/faces/Html/Admin/Upload.xhtml
  </code></pre>
  
  <p>are not entering into Filter.</p>
  
  <p>I have to provide security to these 3 folders.</p>
  
  <p>How to solve this problem ?</p>