Skip to content
Snippets Groups Projects
Forked from DM / dm-docs
261 commits behind, 767 commits ahead of the upstream repository.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
web.xml 2.29 KiB
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="3.1" xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd">
    <context-param>
        <param-name>javax.faces.PROJECT_STAGE</param-name>
        <param-value>Development</param-value>
    </context-param>
    <servlet>
        <servlet-name>Faces Servlet</servlet-name>
        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>*.xhtml</url-pattern>
    </servlet-mapping>
    <session-config>
        <session-timeout>
            30
        </session-timeout>
    </session-config>
    <welcome-file-list>
        <welcome-file>index.xhtml</welcome-file>
    </welcome-file-list>
    <error-page>
        <exception-type>javax.faces.application.ViewExpiredException</exception-type>
        <location>/views/login.xhtml</location>
    </error-page>

    <error-page>
        <exception-type>com.sun.faces.context.FacesFileNotFoundException</exception-type>
        <location>/views/error/pageNotFound.xhtml</location>
    </error-page>

    <error-page>
        <error-code>401</error-code>
        <location>/views/error/accessDenied.xhtml</location>
    </error-page>

    <error-page>
        <error-code>403</error-code>
        <location>/views/error/accessDenied.xhtml</location>
    </error-page>

    <error-page>
        <error-code>404</error-code>
        <location>/views/error/pageNotFound.xhtml</location>
    </error-page>

    <security-constraint>
        <display-name>Restrict Private Files</display-name>
        <web-resource-collection>
            <web-resource-name>Restricted Files</web-resource-name>
            <url-pattern>/templates/*</url-pattern>
            <url-pattern>/views/common/*</url-pattern>
            <url-pattern>/views/experiment/private/*</url-pattern>
            <url-pattern>/views/experimentType/private/*</url-pattern>
            <url-pattern>/views/userInfo/private/*</url-pattern>
        </web-resource-collection>
        <auth-constraint/>                              
    </security-constraint>
</web-app>