<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN' 'http://java.sun.com/j2ee/dtds/web-app_2_2.dtd'>

<web-app>
  <display-name>webapps-simple</display-name>

  <description>
    The jakarta-tomcat-4.0.3 sample apps ports over to S1AS.
  </description>

  <distributable></distributable>

  <servlet>
    <servlet-name>HelloWorldExample</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.HelloWorldExample</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>RequestHeaderExample</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.RequestHeaderExample</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>SnoopServlet</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.SnoopServlet</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>servletToJsp</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.servletToJsp</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>RequestInfoExample</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.RequestInfoExample</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>SessionExample</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.SessionExample</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>CookieExample</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.CookieExample</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>RequestParamExample</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.RequestParamExample</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>SendMailServlet</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.SendMailServlet</servlet-class>
  </servlet>
  <servlet>
    <servlet-name>JndiServlet</servlet-name>
    <servlet-class>samples.webapps.simple.servlet.JndiServlet</servlet-class>
  </servlet>
  <servlet-mapping>
    <servlet-name>HelloWorldExample</servlet-name>
    <url-pattern>/helloworld</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>RequestHeaderExample</servlet-name>
    <url-pattern>/requestheader</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>SnoopServlet</servlet-name>
    <url-pattern>/snoop</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>servletToJsp</servlet-name>
    <url-pattern>/servletToJsp</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>RequestInfoExample</servlet-name>
    <url-pattern>/requestinfo</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>SessionExample</servlet-name>
    <url-pattern>/session</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>CookieExample</servlet-name>
    <url-pattern>/cookie</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>RequestParamExample</servlet-name>
    <url-pattern>/requestparam</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>SendMailServlet</servlet-name>
    <url-pattern>/SendMailServlet</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>JndiServlet</servlet-name>
    <url-pattern>/JndiServlet</url-pattern>
  </servlet-mapping>

  <welcome-file-list>
    <welcome-file>index.html</welcome-file>
  </welcome-file-list>


  <taglib>
    <taglib-uri>http://java.apache.org/tomcat/examples-taglib</taglib-uri>
    <taglib-location>/WEB-INF/tlds/example-taglib.tld</taglib-location>
  </taglib>

  <resource-ref>
    <res-ref-name>mail/Session</res-ref-name>
    <res-type>javax.mail.Session</res-type>
    <res-auth>Container</res-auth>
  </resource-ref>

  <security-constraint>
     <web-resource-collection>
     <web-resource-name>Protected Area</web-resource-name>
	   <!-- Define the context-relative URL(s) to be protected -->
     <url-pattern>/jsp/security/protected/*</url-pattern>
	   <!-- If you list http methods, only those methods are protected -->
	   <http-method>DELETE</http-method>
     <http-method>GET</http-method>
     <http-method>POST</http-method>
	   <http-method>PUT</http-method>
     </web-resource-collection>
     <auth-constraint>
         <!-- Anyone with one of the listed roles may access this area -->
         <role-name>tomcat</role-name>
	   <role-name>role1</role-name>
     </auth-constraint>
  </security-constraint>

  <!-- Environment entry examples -->
    <env-entry>
      <description>
         The maximum number of tax exemptions allowed to be set.
      </description>
      <env-entry-name>maxExemptions</env-entry-name>
      <env-entry-value>15</env-entry-value>
      <env-entry-type>java.lang.Integer</env-entry-type>
    </env-entry>
    <env-entry>
      <env-entry-name>minExemptions</env-entry-name>
      <env-entry-value>1</env-entry-value>
      <env-entry-type>java.lang.Integer</env-entry-type>
    </env-entry>
    <env-entry>
      <env-entry-name>foo/name1</env-entry-name>
      <env-entry-value>value1</env-entry-value>
      <env-entry-type>java.lang.String</env-entry-type>
    </env-entry>
    <env-entry>
      <env-entry-name>foo/bar/name2</env-entry-name>
      <env-entry-value>true</env-entry-value>
      <env-entry-type>java.lang.Boolean</env-entry-type>
    </env-entry>
    <env-entry>
      <env-entry-name>name3</env-entry-name>
      <env-entry-value>1</env-entry-value>
      <env-entry-type>java.lang.Integer</env-entry-type>
    </env-entry>
    <env-entry>
      <env-entry-name>foo/name4</env-entry-name>
      <env-entry-value>10</env-entry-value>
      <env-entry-type>java.lang.Integer</env-entry-type>
    </env-entry>
</web-app>
